/* Óma-Igala UI: the design system for every page (replaces Metronic / Bootstrap).
   Same look as the web chat and mail (nics-chat.css, nics-email.css): Inter, soft canvas, white rounded cards, blue
   accent, pills. Components are prefixed "n-"; the few un-prefixed helpers at the end (d-none, d-flex, gap-*) are kept
   because the chat, mail and call scripts toggle them. Dark mode follows html[data-bs-theme="dark"], which the chat and
   mail stylesheets also read. Behaviour (menus, dialogs, tabs, tables, toasts) lives in wwwroot/js/nics-ui.js; icons in
   Views/Shared/_Icons.cshtml. Reference pages: Views/Department (list with filters and row menu, create and edit forms). */

/* ---------- Tokens ---------- */
:root {
  --n-accent: #1b84ff;
  --n-accent-strong: #0a66d8;
  --n-accent-soft: #e9f3ff;
  --n-accent-softer: #f4f9ff;
  --n-navy: #1e2a47;
  --n-canvas: #eef1f6;
  --n-surface: #ffffff;
  --n-panel: #f8f9fb;
  --n-border: #e6e9f0;
  --n-border-strong: #d5dae5;
  --n-text: #071437;
  --n-text-2: #5e6782;
  --n-text-3: #8d95ab;
  --n-link: #0a66d8;
  --n-on-accent: #ffffff; /* text and icons on a --n-accent fill */
  --n-highlight: #ffc800; /* the active section marker in the navbar */
  --n-danger: #e5484d;
  --n-danger-strong: #c9343a;
  --n-danger-soft: #fdf0f1;
  --n-success: #17a673;
  --n-success-soft: #e8f7f1;
  --n-warning: #b7791f;
  --n-warning-soft: #fff6e5;
  --n-purple: #7239ea;
  --n-purple-soft: #f3eeff;
  --n-shadow-sm: 0 1px 2px rgba(7, 20, 55, 0.06);
  --n-shadow: 0 8px 24px rgba(7, 20, 55, 0.08);
  --n-shadow-lg: 0 18px 48px rgba(7, 20, 55, 0.16);
  --n-r: 10px;
  --n-r-card: 16px;
  --n-pill: 999px;
  --n-font: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --n-mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --n-sidebar-w: 248px;
  --n-sidebar-w-collapsed: 76px;
  --n-topbar-h: 56px;
  --n-gap: 24px;
  color-scheme: light;
}
[data-bs-theme="dark"] {
  --n-accent-soft: #14273f;
  --n-accent-softer: #111c2b;
  --n-canvas: #0d0e12;
  --n-surface: #15171c;
  --n-panel: #1a1c22;
  --n-border: #2a2c35;
  --n-border-strong: #3a3d48;
  --n-text: #f2f3f7;
  --n-text-2: #a5abbf;
  --n-text-3: #7c8299;
  --n-link: #7cc4ff;
  --n-danger-soft: #3a1a1d;
  --n-success-soft: #10302a;
  --n-warning-soft: #33280f;
  --n-purple-soft: #261d3d;
  --n-shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
  --n-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
  --n-shadow-lg: 0 18px 48px rgba(0, 0, 0, 0.5);
  color-scheme: dark;
}

/* ---------- Base ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  -webkit-text-size-adjust: 100%;
}
body {
  margin: 0;
  min-height: 100dvh;
  background: var(--n-canvas);
  color: var(--n-text);
  font-family: var(--n-font);
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
h1,
h2,
h3,
h4,
h5,
h6 {
  margin: 0;
  font-weight: 700;
  line-height: 1.3;
  color: var(--n-text);
}
p,
ul,
ol,
dl,
figure,
blockquote {
  margin: 0;
}
a {
  color: var(--n-link);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}
img,
svg,
video {
  vertical-align: middle;
}
img {
  max-width: 100%;
}
button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}
button {
  cursor: pointer;
}
table {
  border-collapse: collapse;
}
hr {
  margin: 16px 0;
  border: 0;
  border-top: 1px solid var(--n-border);
}
code,
kbd,
pre {
  font-family: var(--n-mono);
  font-size: 0.92em;
}
:focus-visible {
  outline: 2px solid var(--n-accent);
  outline-offset: 2px;
}
[hidden] {
  display: none !important;
}
::selection {
  background: rgba(27, 132, 255, 0.22);
}

/* ---------- Icons (SVG sprite in Views/Shared/_Icons.cshtml) ---------- */
.n-i {
  width: 20px;
  height: 20px;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  vertical-align: middle;
}
.n-i.sm {
  width: 16px;
  height: 16px;
}
.n-i.xs {
  width: 14px;
  height: 14px;
}
.n-i.lg {
  width: 24px;
  height: 24px;
}
.n-i.xl {
  width: 32px;
  height: 32px;
}

/* ---------- App shell ----------
   Social layout (Figma "homePage"): a brand-coloured navbar across the full width (brand, search, the main sections
   in the middle, actions), a light left rail on the page canvas (profile card, menu of round-icon links, "Your account"
   at the foot), the page in the middle and, when a page defines @section Aside, a right rail (.n-aside). */
.n-shell {
  display: grid;
  grid-template-columns: var(--n-sidebar-w) minmax(0, 1fr);
  grid-template-rows: var(--n-topbar-h) minmax(0, 1fr);
  min-height: 100dvh;
}

/* Navbar */
.n-topbar {
  grid-column: 1 / -1;
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 12px;
  height: var(--n-topbar-h);
  padding: 0 20px 0 16px;
  background: var(--n-navy);
  color: #fff;
  box-shadow: 0 2px 4px rgba(9, 30, 66, 0.13);
  color-scheme: dark;
}
.n-topbar .n-icon-btn {
  color: rgba(255, 255, 255, 0.86);
}
.n-topbar .n-icon-btn:hover,
.n-topbar .n-icon-btn[aria-expanded="true"] {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
}
.n-topbar .n-icon-btn:focus-visible,
.n-topbar a:focus-visible,
.n-topbar button:focus-visible {
  outline: 2px solid var(--n-highlight);
  outline-offset: 2px;
}
.n-topbar .n-count-dot {
  border-color: var(--n-navy);
}
.n-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: none;
  width: calc(var(--n-sidebar-w) - 16px - 12px - 40px - 12px);
  min-width: 0;
  color: #fff;
  text-decoration: none;
}
.n-brand:hover {
  color: #fff;
  text-decoration: none;
}
.n-brand-mark {
  display: block;
  flex: none;
  width: 40px;
  height: 40px;
}
.n-brand-text {
  overflow: hidden;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.01em;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.n-topsearch {
  position: relative;
  display: flex;
  align-items: center;
  flex: 0 1 366px;
  min-width: 180px;
}
.n-topsearch .n-i {
  position: absolute;
  left: 8px;
  color: var(--n-text-3);
  pointer-events: none;
}
.n-topsearch input {
  width: 100%;
  height: 34px;
  padding: 0 10px 0 32px;
  border: 2px solid var(--n-border);
  border-radius: 6px;
  background: var(--n-surface);
  color: var(--n-text);
  font-size: 14px;
  outline: none;
}
.n-topsearch input::placeholder {
  color: var(--n-text-3);
}
.n-topsearch input:focus {
  border-color: var(--n-accent);
}
/* The main sections, centred in the space left between the search and the actions */
.n-toptabs {
  display: flex;
  flex: 1;
  justify-content: center;
  gap: 32px;
  min-width: 0;
}
.n-toptab {
  position: relative;
  display: inline-grid;
  place-items: center;
  width: 48px;
  height: var(--n-topbar-h);
  color: rgba(255, 255, 255, 0.62);
  text-decoration: none;
  transition: color 0.12s;
}
.n-toptab .n-i {
  width: 24px;
  height: 24px;
}
.n-toptab:hover {
  color: #fff;
  text-decoration: none;
}
.n-toptab[aria-current="page"] {
  color: #fff;
}
.n-toptab[aria-current="page"]::after {
  content: "";
  position: absolute;
  right: 8px;
  bottom: 0;
  left: 8px;
  height: 3px;
  border-radius: 3px 3px 0 0;
  background: var(--n-highlight);
}
.n-topactions {
  display: flex;
  align-items: center;
  gap: 4px;
  flex: none;
  margin-left: auto;
}
.n-topbar .n-avatar-btn {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  height: 40px;
  margin-left: 6px;
  padding: 0 2px;
  border: 0;
  border-radius: var(--n-pill);
  background: transparent;
  color: #fff;
}
.n-topbar .n-avatar-btn .n-avatar {
  width: 32px;
  height: 32px;
}
.n-topbar .n-avatar-btn:hover .n-avatar,
.n-topbar .n-avatar-btn[aria-expanded="true"] .n-avatar {
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.5);
}
.n-count-dot {
  position: absolute;
  top: 3px;
  right: 3px;
  display: inline-grid;
  place-items: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border: 2px solid var(--n-canvas);
  border-radius: var(--n-pill);
  background: var(--n-danger);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  line-height: 1;
}

/* Left rail */
.n-sidebar {
  position: sticky;
  top: var(--n-topbar-h);
  z-index: 20;
  display: flex;
  flex-direction: column;
  height: calc(100dvh - var(--n-topbar-h));
  padding: 24px 0 16px;
  border-right: 1px solid var(--n-border);
  background: var(--n-sidebar, var(--n-canvas));
}
.n-sidebar .n-nav-link:hover {
  background: var(--n-sidebar-hover, var(--n-panel));
}
.n-sidebar .n-nav-link[aria-current="page"] {
  background: var(--n-sidebar-current, var(--n-surface));
}
.n-profilecard {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: none;
  margin: 0 12px 12px;
  padding: 6px;
  border-radius: 14px;
  color: var(--n-text);
  text-decoration: none;
}
.n-profilecard:hover {
  background: var(--n-panel);
  color: var(--n-text);
  text-decoration: none;
}
.n-profilecard .n-avatar {
  flex: none;
  width: 48px;
  height: 48px;
  box-shadow: 0 0 0 2px var(--n-canvas), 0 0 0 4px var(--n-accent);
}
.n-profilecard-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
  line-height: 1.5;
}
.n-profilecard-text b {
  overflow: hidden;
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.n-profilecard-text span {
  overflow: hidden;
  font-size: 11px;
  color: var(--n-text-2);
  white-space: nowrap;
  text-overflow: ellipsis;
}
.n-nav {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 0 12px 16px;
  scrollbar-width: thin;
}
.n-nav-section {
  margin: 20px 12px 8px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--n-text);
  white-space: nowrap;
}
.n-nav > .n-nav-section:first-child {
  margin-top: 4px;
}
.n-nav-link {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  height: 44px;
  margin: 4px 0;
  padding: 0 12px 0 4px;
  border: 0;
  border-radius: 24px;
  background: transparent;
  color: var(--n-accent-strong);
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  text-align: left;
  white-space: nowrap;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.12s, color 0.12s;
}
[data-bs-theme="dark"] .n-nav-link {
  color: var(--n-text);
}
.n-nav-link:hover {
  background: var(--n-panel);
  text-decoration: none;
}
/* The round icon chip in front of every link */
.n-nav-icon {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--n-accent-soft);
  color: var(--n-accent-strong);
  transition: background 0.12s, color 0.12s;
}
.n-nav-icon .n-i {
  width: 18px;
  height: 18px;
}
[data-bs-theme="dark"] .n-nav-icon {
  color: var(--n-link);
}
.n-nav-link[aria-current="page"] {
  background: var(--n-surface);
  box-shadow: var(--n-shadow-sm);
}
.n-nav-link[aria-current="page"] .n-nav-icon {
  background: var(--n-accent);
  color: var(--n-on-accent);
}
.n-nav-link:focus-visible {
  outline: 2px solid var(--n-accent);
  outline-offset: 1px;
}
.n-nav-label {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}
.n-nav-badge {
  display: inline-grid;
  place-items: center;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: var(--n-pill);
  background: var(--n-danger);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
}
.n-nav-badge.info {
  background: var(--n-accent);
  color: var(--n-on-accent);
}
.n-sidebar-foot {
  flex: none;
  padding: 8px 12px 0;
}
.n-sidebar-foot .n-nav-section {
  margin-top: 4px;
}
.n-sidebar-foot form {
  margin: 0;
}

/* Page area */
.n-main {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: calc(100dvh - var(--n-topbar-h));
}
.n-content {
  flex: 1;
  padding: var(--n-gap);
  /* the chat and mail panes size themselves from these */
  --nch-height: calc(100dvh - var(--n-topbar-h) - 2 * var(--n-gap));
  --nem-height: calc(100dvh - var(--n-topbar-h) - 2 * var(--n-gap));
}
.n-container {
  width: 100%;
  max-width: 1440px;
  margin: 0 auto;
}
.n-content.bleed .n-container {
  max-width: none;
}
/* room under the last card so the floating Feedback button never covers its buttons */
.n-content:not(.bleed) {
  padding-bottom: calc(var(--n-gap) + 56px);
}
/* Right rail (@section Aside): beside the page from 1200px, under it below that */
.n-with-aside {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--n-gap);
  align-items: start;
}
.n-aside {
  display: flex;
  flex-direction: column;
  gap: 32px;
  min-width: 0;
}
@media (min-width: 1200px) {
  .n-with-aside {
    grid-template-columns: minmax(0, 1fr) 300px;
  }
  .n-aside {
    position: sticky;
    top: calc(var(--n-topbar-h) + var(--n-gap));
    max-height: calc(100dvh - var(--n-topbar-h) - 2 * var(--n-gap));
    overflow-y: auto;
    scrollbar-width: thin;
  }
}
/* Right-rail blocks: a heading row with round actions, then a list (chats, products) */
.n-rail {
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 0;
}
.n-rail-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.n-rail-title {
  font-size: 16px;
  font-weight: 600;
  line-height: 1.5;
  color: var(--n-text);
}
.n-rail-actions {
  display: flex;
  gap: 8px;
}
.n-rail-actions .n-icon-btn {
  background: var(--n-accent-soft);
  color: var(--n-accent-strong);
}
.n-rail-actions .n-icon-btn:hover {
  background: var(--n-accent);
  color: var(--n-on-accent);
}
.n-rail-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.n-rail-note {
  font-size: 12.5px;
  color: var(--n-text-2);
}
.n-rail-more {
  align-self: flex-start;
  font-size: 12.5px;
}
.n-chatrow {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: -6px;
  padding: 6px;
  border-radius: 12px;
  color: var(--n-text);
  text-decoration: none;
}
.n-chatrow:hover {
  background: var(--n-panel);
  color: var(--n-text);
  text-decoration: none;
}
.n-chatrow-body {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
  min-width: 0;
}
.n-chatrow-top,
.n-chatrow-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-width: 0;
}
.n-chatrow-top b {
  font-size: 14px;
  font-weight: 500;
}
.n-chatrow.unread .n-chatrow-top b {
  font-weight: 700;
}
.n-chatrow-top time {
  flex: none;
  font-size: 11px;
  color: var(--n-link);
}
.n-chatrow-bottom {
  font-size: 11.5px;
  color: var(--n-text-2);
}
.n-chatrow-count {
  display: inline-grid;
  place-items: center;
  flex: none;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  border-radius: var(--n-pill);
  background: var(--n-danger);
  color: #fff;
  font-size: 9px;
  font-weight: 700;
  line-height: 1;
}
.n-product {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
a.n-product {
  margin: -6px;
  padding: 6px;
  border-radius: var(--n-r);
  color: inherit;
  text-decoration: none;
}
a.n-product:hover {
  background: var(--n-panel);
}
.n-product-photo {
  display: grid;
  place-items: center;
  flex: none;
  width: 80px;
  height: 80px;
  overflow: hidden;
  border-radius: 16px;
  background: var(--n-accent-soft);
  color: var(--n-accent-strong);
}
.n-product-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.n-product-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  line-height: 1.5;
}
.n-product-text b {
  font-size: 14px;
  font-weight: 500;
}
.n-product-price {
  font-size: 14px;
  font-weight: 600;
  color: var(--n-accent-strong);
}
[data-bs-theme="dark"] .n-product-price {
  color: var(--n-link);
}
.n-product-seller {
  font-size: 12px;
  color: var(--n-text-2);
}
.n-footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 20px;
  padding: 14px var(--n-gap) 20px;
  font-size: 12.5px;
  color: var(--n-text-3);
}
.n-footer a {
  color: var(--n-text-2);
}
.n-backdrop {
  display: none;
}
.n-icon-btn.n-menu-toggle {
  display: none;
}
.n-feedback-btn {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 1050;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 44px;
  padding: 0 18px;
  border: 0;
  border-radius: var(--n-pill);
  background: var(--n-accent);
  color: #fff;
  font-weight: 600;
  box-shadow: 0 8px 20px rgba(27, 132, 255, 0.35);
}
.n-feedback-btn:hover {
  background: var(--n-accent-strong);
}

/* Collapsed rail (desktop): icon chips only */
html.n-collapsed .n-shell {
  grid-template-columns: var(--n-sidebar-w-collapsed) minmax(0, 1fr);
}
html.n-collapsed .n-profilecard {
  justify-content: center;
  margin: 0 8px 12px;
}
html.n-collapsed .n-profilecard-text,
html.n-collapsed .n-nav-label {
  display: none;
}
html.n-collapsed .n-nav,
html.n-collapsed .n-sidebar-foot {
  padding-right: 8px;
  padding-left: 8px;
}
html.n-collapsed .n-nav-section {
  height: 1px;
  margin: 12px 10px;
  overflow: hidden;
  background: var(--n-border);
  color: transparent;
}
html.n-collapsed .n-nav-link {
  justify-content: center;
  padding: 0;
}
html.n-collapsed .n-nav-badge {
  position: absolute;
  top: 2px;
  right: 6px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  font-size: 10px;
}

@media (max-width: 1199.98px) {
  .n-toptabs {
    gap: 8px;
  }
}
@media (max-width: 991.98px) {
  :root {
    --n-gap: 16px;
    --n-topbar-h: 56px;
  }
  .n-shell,
  html.n-collapsed .n-shell {
    grid-template-columns: minmax(0, 1fr);
  }
  .n-topbar {
    gap: 8px;
    padding: 0 8px;
  }
  .n-brand {
    width: auto;
  }
  /* The rail becomes a drawer over the page */
  .n-sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 40;
    width: min(300px, 86vw);
    height: 100dvh;
    padding-top: 20px;
    background: var(--n-surface);
    transform: translateX(-102%);
    transition: transform 0.2s ease;
    box-shadow: var(--n-shadow-lg);
  }
  html.n-nav-open .n-sidebar {
    transform: none;
  }
  html.n-collapsed .n-profilecard {
    justify-content: flex-start;
    margin: 0 12px 12px;
  }
  html.n-collapsed .n-profilecard-text {
    display: flex;
  }
  html.n-collapsed .n-nav-label {
    display: block;
  }
  html.n-collapsed .n-nav,
  html.n-collapsed .n-sidebar-foot {
    padding-right: 12px;
    padding-left: 12px;
  }
  html.n-collapsed .n-nav-link {
    justify-content: flex-start;
    padding: 0 12px 0 4px;
  }
  html.n-collapsed .n-nav-section {
    height: auto;
    margin: 20px 12px 8px;
    background: none;
    color: var(--n-text);
  }
  html.n-collapsed .n-nav-badge {
    position: static;
  }
  .n-backdrop {
    position: fixed;
    inset: 0;
    z-index: 35;
    background: rgba(7, 20, 55, 0.4);
  }
  html.n-nav-open .n-backdrop {
    display: block;
  }
  .n-icon-btn.n-menu-toggle {
    display: inline-grid;
  }
  .n-icon-btn.n-collapse-toggle,
  .n-topsearch {
    display: none;
  }
  .n-feedback-btn span {
    display: none;
  }
  .n-feedback-btn {
    width: 48px;
    padding: 0;
    justify-content: center;
  }
}
/* Pages that keep the rail as a drawer at every width (ViewData["RailDrawer"], e.g. Messages) */
@media (min-width: 992px) {
  .n-shell.rail-drawer {
    grid-template-columns: minmax(0, 1fr);
  }
  .rail-drawer .n-sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 40;
    width: 300px;
    height: 100dvh;
    padding-top: 20px;
    background: var(--n-surface);
    transform: translateX(-102%);
    transition: transform 0.2s ease;
    box-shadow: var(--n-shadow-lg);
  }
  html.n-nav-open .rail-drawer .n-sidebar {
    transform: none;
  }
  .rail-drawer .n-backdrop {
    position: fixed;
    inset: 0;
    z-index: 35;
    background: rgba(7, 20, 55, 0.4);
  }
  html.n-nav-open .rail-drawer .n-backdrop {
    display: block;
  }
  .rail-drawer .n-icon-btn.n-menu-toggle {
    display: inline-grid;
  }
  .rail-drawer .n-icon-btn.n-collapse-toggle {
    display: none;
  }
  /* the menu button sits in front of the brand, so the brand gives up its width */
  .rail-drawer .n-brand {
    width: calc(var(--n-sidebar-w) - 16px - 12px - 40px - 12px);
  }
  .rail-drawer .n-content.bleed .n-container {
    max-width: 1240px;
  }
}
@media (max-width: 767.98px) {
  .n-toptabs {
    display: none;
  }
}
@media (max-width: 399.98px) {
  .n-brand-text {
    display: none;
  }
}
@media (min-width: 992px) {
  .n-icon-btn.n-search-link {
    display: none;
  }
  .n-footer {
    padding-right: 170px; /* clear of the Feedback button */
  }
}

/* ---------- Page header ---------- */
.n-page-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 12px 16px;
  margin-bottom: 20px;
}
.n-page-head-text {
  flex: 1;
  min-width: 220px;
}
.n-page-title {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.01em;
}
.n-page-sub {
  margin-top: 4px;
  color: var(--n-text-2);
}
.n-page-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.n-crumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-bottom: 6px;
  padding: 0;
  list-style: none;
  font-size: 12.5px;
  color: var(--n-text-3);
}
.n-crumbs li + li::before {
  content: "/";
  margin-right: 6px;
  color: var(--n-border-strong);
}
.n-crumbs a {
  color: var(--n-text-2);
}

/* ---------- Layout helpers ---------- */
.n-stack {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.n-stack.tight {
  gap: 8px;
}
.n-stack.loose {
  gap: 24px;
}
.n-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
}
.n-row.nowrap {
  flex-wrap: nowrap;
}
.n-row.between {
  justify-content: space-between;
}
.n-row.end {
  justify-content: flex-end;
}
.n-row.center {
  justify-content: center;
}
.n-row.top {
  align-items: flex-start;
}
.n-spacer {
  flex: 1;
}
.n-grid {
  display: grid;
  gap: 20px;
  grid-template-columns: minmax(0, 1fr);
}
@media (min-width: 768px) {
  .n-grid.cols-2,
  .n-grid.cols-3,
  .n-grid.cols-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .n-grid.sidebar-left {
    grid-template-columns: 260px minmax(0, 1fr);
  }
  .n-grid.sidebar-right {
    grid-template-columns: minmax(0, 1fr) 320px;
  }
}
@media (min-width: 1200px) {
  .n-grid.cols-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .n-grid.cols-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}
.n-span-2 {
  grid-column: span 2;
}
@media (max-width: 767.98px) {
  .n-span-2 {
    grid-column: auto;
  }
}
.n-narrow {
  max-width: 760px;
}
.n-narrow.center {
  margin-left: auto;
  margin-right: auto;
}

/* ---------- Card ---------- */
.n-card {
  min-width: 0;
  border: 1px solid var(--n-border);
  border-radius: var(--n-r-card);
  background: var(--n-surface);
  box-shadow: var(--n-shadow-sm);
}
.n-card-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 12px;
  padding: 18px 20px;
  border-bottom: 1px solid var(--n-border);
}
.n-card-head.plain {
  border-bottom: 0;
  padding-bottom: 0;
}
.n-card-title {
  font-size: 15.5px;
  font-weight: 700;
}
.n-card-sub {
  margin-top: 2px;
  font-size: 13px;
  color: var(--n-text-3);
}
.n-card-head > :first-child {
  flex: 1;
  min-width: 180px;
}
.n-card-body {
  padding: 20px;
}
.n-card-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  padding: 14px 20px;
  border-top: 1px solid var(--n-border);
  background: var(--n-panel);
  border-radius: 0 0 var(--n-r-card) var(--n-r-card);
}
.n-card.danger {
  border-color: color-mix(in srgb, var(--n-danger) 40%, var(--n-border));
}
.n-card.hero {
  position: relative;
  overflow: hidden;
  border: 0;
  background: linear-gradient(120deg, var(--n-navy), #2b4170 60%, #1b5fbf);
  color: #fff;
}
.n-card.hero h2,
.n-card.hero h1 {
  color: #fff;
}
.n-card.hero .n-muted {
  color: rgba(255, 255, 255, 0.75);
}
.n-section-title {
  margin-bottom: 10px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--n-text-3);
}

/* ---------- Stat tile ---------- */
.n-stat {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 20px;
}
.n-stat-top {
  display: flex;
  align-items: center;
  gap: 12px;
}
.n-stat-icon {
  display: grid;
  place-items: center;
  flex: none;
  width: 44px;
  height: 44px;
  border-radius: 12px;
}
.n-stat-value {
  font-size: 28px;
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.02em;
}
.n-stat-label {
  font-size: 13px;
  color: var(--n-text-2);
}
.n-stat-meta {
  font-size: 12.5px;
  color: var(--n-text-3);
}

/* Tones (icon tiles, badges, alerts, avatars) */
.tone-blue {
  --tone: var(--n-accent-strong);
  --tone-soft: var(--n-accent-soft);
}
.tone-green {
  --tone: var(--n-success);
  --tone-soft: var(--n-success-soft);
}
.tone-amber {
  --tone: var(--n-warning);
  --tone-soft: var(--n-warning-soft);
}
.tone-red {
  --tone: var(--n-danger);
  --tone-soft: var(--n-danger-soft);
}
.tone-purple {
  --tone: var(--n-purple);
  --tone-soft: var(--n-purple-soft);
}
.tone-gray {
  --tone: var(--n-text-2);
  --tone-soft: var(--n-panel);
}
[data-bs-theme="dark"] .tone-blue {
  --tone: var(--n-link);
}
[data-bs-theme="dark"] .tone-purple {
  --tone: #b69cff;
}
.n-stat-icon,
.n-tile {
  background: var(--tone-soft, var(--n-accent-soft));
  color: var(--tone, var(--n-accent-strong));
}
.n-tile {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 40px;
  height: 40px;
  border-radius: 12px;
}
.n-tile.sm {
  width: 32px;
  height: 32px;
  border-radius: 9px;
}

/* ---------- Buttons ---------- */
.n-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 40px;
  padding: 0 16px;
  border: 1px solid var(--n-border);
  border-radius: var(--n-r);
  background: var(--n-surface);
  color: var(--n-text);
  font-size: 14px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.12s, border-color 0.12s, color 0.12s, box-shadow 0.12s;
}
.n-btn:hover {
  border-color: var(--n-border-strong);
  background: var(--n-panel);
  text-decoration: none;
}
.n-btn.primary {
  border-color: var(--n-accent);
  background: var(--n-accent);
  color: #fff;
}
.n-btn.primary:hover {
  border-color: var(--n-accent-strong);
  background: var(--n-accent-strong);
}
.n-btn.danger {
  border-color: var(--n-danger);
  background: var(--n-danger);
  color: #fff;
}
.n-btn.danger:hover {
  border-color: var(--n-danger-strong);
  background: var(--n-danger-strong);
}
.n-btn.success {
  border-color: var(--n-success);
  background: var(--n-success);
  color: #fff;
}
.n-btn.success:hover {
  filter: brightness(0.94);
}
.n-btn.soft {
  border-color: transparent;
  background: var(--n-accent-soft);
  color: var(--n-accent-strong);
}
[data-bs-theme="dark"] .n-btn.soft {
  color: var(--n-link);
}
.n-btn.soft:hover {
  background: color-mix(in srgb, var(--n-accent-soft) 70%, var(--n-accent) 30%);
}
.n-btn.ghost {
  border-color: transparent;
  background: transparent;
  color: var(--n-text-2);
}
.n-btn.ghost:hover {
  background: var(--n-panel);
  color: var(--n-text);
}
.n-btn.ghost-danger {
  border-color: transparent;
  background: transparent;
  color: var(--n-danger);
}
.n-btn.ghost-danger:hover {
  background: var(--n-danger-soft);
}
.n-btn.sm {
  height: 32px;
  padding: 0 12px;
  border-radius: 8px;
  font-size: 13px;
  gap: 6px;
}
.n-btn.lg {
  height: 46px;
  padding: 0 22px;
  font-size: 15px;
}
.n-btn.block {
  width: 100%;
}
.n-btn.icon {
  width: 40px;
  padding: 0;
}
.n-btn.icon.sm {
  width: 32px;
}
.n-btn:disabled,
.n-btn[aria-disabled="true"] {
  opacity: 0.55;
  cursor: not-allowed;
  pointer-events: none;
}
.n-btn[aria-busy="true"] {
  position: relative;
  color: transparent !important;
  pointer-events: none;
}
.n-btn[aria-busy="true"] > * {
  visibility: hidden;
}
.n-btn[aria-busy="true"]::after {
  content: "";
  position: absolute;
  width: 18px;
  height: 18px;
  border: 2px solid currentColor;
  border-color: var(--n-text-3) var(--n-text-3) var(--n-text-3) transparent;
  border-radius: 50%;
  animation: n-spin 0.7s linear infinite;
}
.n-btn.primary[aria-busy="true"]::after,
.n-btn.danger[aria-busy="true"]::after,
.n-btn.success[aria-busy="true"]::after {
  border-color: #fff #fff #fff transparent;
}
.n-icon-btn {
  position: relative;
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--n-text-2);
  text-decoration: none;
  cursor: pointer;
  transition: background 0.12s, color 0.12s;
}
.n-icon-btn:hover,
.n-icon-btn[aria-expanded="true"] {
  background: var(--n-accent-soft);
  color: var(--n-accent-strong);
  text-decoration: none;
}
.n-icon-btn.sm {
  width: 32px;
  height: 32px;
}
.n-icon-btn.danger:hover {
  background: var(--n-danger-soft);
  color: var(--n-danger);
}
.n-btn-group {
  display: inline-flex;
}
.n-btn-group > .n-btn {
  border-radius: 0;
}
.n-btn-group > .n-btn:first-child {
  border-radius: var(--n-r) 0 0 var(--n-r);
}
.n-btn-group > .n-btn:last-child {
  border-radius: 0 var(--n-r) var(--n-r) 0;
}
.n-btn-group > .n-btn + .n-btn {
  margin-left: -1px;
}

/* ---------- Forms ---------- */
.n-form {
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.n-form-grid {
  display: grid;
  gap: 18px 20px;
  grid-template-columns: minmax(0, 1fr);
}
@media (min-width: 768px) {
  .n-form-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .n-form-grid > .full {
    grid-column: 1 / -1;
  }
}
.n-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}
.n-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--n-text);
}
.n-label .req,
.n-label.required::after {
  color: var(--n-danger);
}
.n-label.required::after {
  content: " *";
}
.n-help {
  font-size: 12.5px;
  color: var(--n-text-3);
}
.n-input,
.n-select,
.n-textarea {
  width: 100%;
  min-height: 42px;
  padding: 9px 12px;
  border: 1px solid var(--n-border);
  border-radius: var(--n-r);
  background: var(--n-surface);
  color: var(--n-text);
  font-size: 14px;
  outline: none;
  transition: border-color 0.12s, box-shadow 0.12s;
}
.n-input::placeholder,
.n-textarea::placeholder {
  color: var(--n-text-3);
}
.n-input:hover,
.n-select:hover,
.n-textarea:hover {
  border-color: var(--n-border-strong);
}
.n-input:focus,
.n-select:focus,
.n-textarea:focus {
  border-color: var(--n-accent);
  box-shadow: 0 0 0 3px rgba(27, 132, 255, 0.14);
}
.n-input:disabled,
.n-select:disabled,
.n-textarea:disabled,
.n-input[readonly] {
  background: var(--n-panel);
  color: var(--n-text-2);
}
.n-input.sm,
.n-select.sm {
  min-height: 34px;
  padding: 5px 10px;
  font-size: 13px;
}
.n-textarea {
  min-height: 96px;
  resize: vertical;
  line-height: 1.5;
}
.n-select {
  appearance: none;
  padding-right: 36px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%238d95ab' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 16px;
}
.n-select[multiple] {
  padding-right: 12px;
  background-image: none;
}
.n-input-icon {
  position: relative;
  display: flex;
  align-items: center;
}
.n-input-icon > .n-i {
  position: absolute;
  left: 12px;
  color: var(--n-text-3);
  pointer-events: none;
}
.n-input-icon > .n-input {
  padding-left: 38px;
}
.n-input-group {
  display: flex;
}
.n-input-group > .n-input {
  border-radius: var(--n-r) 0 0 var(--n-r);
}
.n-input-group > .n-btn {
  border-radius: 0 var(--n-r) var(--n-r) 0;
  margin-left: -1px;
}
.n-input-addon {
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
  border: 1px solid var(--n-border);
  border-left: 0;
  border-radius: 0 var(--n-r) var(--n-r) 0;
  background: var(--n-panel);
  color: var(--n-text-2);
  font-size: 13px;
}
.n-check {
  display: inline-flex;
  align-items: flex-start;
  gap: 10px;
  cursor: pointer;
  line-height: 1.4;
}
.n-check input {
  flex: none;
  width: 18px;
  height: 18px;
  margin: 1px 0 0;
  accent-color: var(--n-accent);
  cursor: pointer;
}
.n-check-text {
  display: flex;
  flex-direction: column;
}
.n-check-text small {
  font-size: 12.5px;
  color: var(--n-text-3);
}
.n-switch {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
}
.n-switch input {
  position: relative;
  flex: none;
  width: 40px;
  height: 22px;
  margin: 0;
  border-radius: var(--n-pill);
  background: var(--n-border-strong);
  appearance: none;
  cursor: pointer;
  transition: background 0.15s;
}
.n-switch input::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
  transition: transform 0.15s;
}
.n-switch input:checked {
  background: var(--n-accent);
}
.n-switch input:checked::after {
  transform: translateX(18px);
}
.n-switch input:disabled {
  opacity: 0.5;
}
.n-setting {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid var(--n-border);
}
.n-setting:last-child {
  border-bottom: 0;
}
.n-setting-text {
  flex: 1;
  min-width: 0;
}
.n-setting-text b {
  display: block;
  font-weight: 600;
}
.n-setting-text span {
  font-size: 13px;
  color: var(--n-text-3);
}
.n-form-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
  padding-top: 4px;
}
fieldset.n-fieldset {
  margin: 0;
  padding: 0;
  border: 0;
  min-width: 0;
}
fieldset.n-fieldset > legend {
  margin-bottom: 10px;
  padding: 0;
  font-size: 13px;
  font-weight: 700;
  color: var(--n-text);
}

/* ASP.NET / jquery-validation states */
.n-input.input-validation-error,
.n-select.input-validation-error,
.n-textarea.input-validation-error,
.n-input.is-invalid,
.n-select.is-invalid,
.n-textarea.is-invalid {
  border-color: var(--n-danger);
}
.n-input.is-invalid:focus,
.n-select.is-invalid:focus,
.n-textarea.is-invalid:focus,
.n-input.input-validation-error:focus {
  box-shadow: 0 0 0 3px rgba(229, 72, 77, 0.15);
}
.n-error,
.field-validation-error,
.invalid-feedback {
  display: block;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--n-danger);
}
.field-validation-valid,
.n-error:empty,
.invalid-feedback:empty {
  display: none;
}
.validation-summary-errors {
  padding: 12px 14px;
  border: 1px solid color-mix(in srgb, var(--n-danger) 35%, transparent);
  border-radius: var(--n-r);
  background: var(--n-danger-soft);
  color: var(--n-danger);
  font-size: 13px;
}
.validation-summary-errors ul {
  margin: 0;
  padding-left: 18px;
}
.validation-summary-valid {
  display: none;
}

/* File drop area (input[type=file] inside label.n-drop; nics-ui.js shows the chosen names) */
.n-drop {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 150px;
  padding: 24px;
  border: 1.5px dashed var(--n-border-strong);
  border-radius: var(--n-r-card);
  background: var(--n-panel);
  color: var(--n-text-2);
  text-align: center;
  cursor: pointer;
  transition: border-color 0.12s, background 0.12s;
}
.n-drop:hover,
.n-drop.dragging {
  border-color: var(--n-accent);
  background: var(--n-accent-softer);
}
.n-drop input[type="file"] {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
}
.n-drop b {
  color: var(--n-text);
}
.n-drop-files {
  font-size: 13px;
  font-weight: 600;
  color: var(--n-accent-strong);
}

/* ---------- Tables ---------- */
.n-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  padding: 14px 20px;
  border-bottom: 1px solid var(--n-border);
}
.n-toolbar .n-input-icon {
  flex: 1 1 240px;
  max-width: 360px;
}
.n-toolbar .n-select {
  width: auto;
  min-width: 150px;
}
@media (max-width: 575.98px) {
  .n-toolbar > .n-input-icon,
  .n-toolbar > .n-select,
  .n-toolbar > .n-input {
    flex: 1 1 100%;
    max-width: none;
  }
  .n-toolbar > .n-btn {
    flex: 1 1 0;
  }
}
.n-table-wrap {
  position: relative; /* keeps absolutely positioned bits (e.g. .n-sr labels in headers) inside the scroll area */
  width: 100%;
  overflow-x: auto;
}
.n-table {
  width: 100%;
  font-size: 13.5px;
}
.n-table th {
  padding: 11px 16px;
  border-bottom: 1px solid var(--n-border);
  background: var(--n-panel);
  color: var(--n-text-3);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-align: left;
  text-transform: uppercase;
  white-space: nowrap;
}
.n-table td {
  padding: 13px 16px;
  border-bottom: 1px solid var(--n-border);
  vertical-align: middle;
}
.n-table tbody tr:last-child td {
  border-bottom: 0;
}
.n-table tbody tr:hover td {
  background: var(--n-accent-softer);
}
.n-table th:first-child,
.n-table td:first-child {
  padding-left: 20px;
}
.n-table th:last-child,
.n-table td:last-child {
  padding-right: 20px;
}
.n-table .num,
.n-table .end {
  text-align: right;
}
.n-table .shrink {
  width: 1%;
  white-space: nowrap;
}
.n-table th .n-sort {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  letter-spacing: inherit;
  text-transform: inherit;
  cursor: pointer;
}
.n-table th .n-sort:hover {
  color: var(--n-text);
}
.n-table th[aria-sort="ascending"] .n-sort::after {
  content: "▲";
  font-size: 9px;
}
.n-table th[aria-sort="descending"] .n-sort::after {
  content: "▼";
  font-size: 9px;
}
.n-table.compact td {
  padding-top: 9px;
  padding-bottom: 9px;
}
.n-card > .n-table-wrap:last-child .n-table tbody tr:last-child td:first-child {
  border-bottom-left-radius: var(--n-r-card);
}
.n-card > .n-table-wrap:last-child .n-table tbody tr:last-child td:last-child {
  border-bottom-right-radius: var(--n-r-card);
}
.n-table-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 20px;
  border-top: 1px solid var(--n-border);
  font-size: 13px;
  color: var(--n-text-3);
}
.n-person {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}
.n-person-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
  line-height: 1.35;
}
.n-person-text b,
.n-person-text a {
  font-weight: 600;
  color: var(--n-text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.n-person-text a:hover {
  color: var(--n-accent-strong);
}
.n-person-text span {
  font-size: 12.5px;
  color: var(--n-text-3);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.n-actions {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 2px;
}

/* ---------- Pagination ---------- */
.n-pager {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.n-pager a,
.n-pager span,
.n-pager button {
  display: inline-grid;
  place-items: center;
  min-width: 34px;
  height: 34px;
  padding: 0 10px;
  border: 1px solid transparent;
  border-radius: 9px;
  background: transparent;
  color: var(--n-text-2);
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
}
.n-pager a:hover,
.n-pager button:hover:not(:disabled) {
  border-color: var(--n-border);
  background: var(--n-surface);
  color: var(--n-text);
}
.n-pager [aria-current="page"],
.n-pager .active {
  background: var(--n-accent);
  color: #fff;
}
.n-pager [aria-disabled="true"],
.n-pager button:disabled {
  opacity: 0.45;
  pointer-events: none;
}

/* ---------- Avatar ---------- */
.n-avatar {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 40px;
  height: 40px;
  overflow: hidden;
  border-radius: 50%;
  background: var(--tone-soft, var(--n-accent-soft));
  color: var(--tone, var(--n-accent-strong));
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}
.n-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.n-avatar.xs {
  width: 26px;
  height: 26px;
  font-size: 10.5px;
}
.n-avatar.sm {
  width: 32px;
  height: 32px;
  font-size: 12px;
}
.n-avatar.lg {
  width: 56px;
  height: 56px;
  font-size: 19px;
}
.n-avatar.xl {
  width: 96px;
  height: 96px;
  font-size: 32px;
}
.n-avatar.square {
  border-radius: 12px;
}

/* ---------- Badges ---------- */
.n-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  height: 24px;
  padding: 0 9px;
  border-radius: var(--n-pill);
  background: var(--tone-soft, var(--n-panel));
  color: var(--tone, var(--n-text-2));
  font-size: 12px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
}
.n-badge.dot::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}
.n-badge.solid {
  background: var(--tone, var(--n-accent));
  color: #fff;
}
.n-badge.outline {
  border: 1px solid var(--n-border);
  background: transparent;
}
.n-badge.sm {
  height: 20px;
  padding: 0 7px;
  font-size: 11px;
}
.n-count {
  display: inline-grid;
  place-items: center;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: var(--n-pill);
  background: var(--n-accent);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
}

/* ---------- Alerts ---------- */
.n-alert {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 16px;
  border: 1px solid color-mix(in srgb, var(--tone, var(--n-accent)) 28%, transparent);
  border-radius: 12px;
  background: var(--tone-soft, var(--n-accent-soft));
  color: var(--n-text);
  font-size: 13.5px;
}
.n-alert > .n-i {
  margin-top: 1px;
  color: var(--tone, var(--n-accent-strong));
}
.n-alert-body {
  flex: 1;
  min-width: 0;
}
.n-alert-title {
  display: block;
  margin-bottom: 2px;
  font-weight: 700;
}

/* ---------- Tabs ---------- */
.n-tabs {
  position: relative;
  display: flex;
  gap: 4px;
  overflow-x: auto;
  border-bottom: 1px solid var(--n-border);
  scrollbar-width: none;
}
.n-tabs::-webkit-scrollbar {
  display: none;
}
.n-tab {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: none;
  height: 44px;
  padding: 0 14px;
  border: 0;
  background: transparent;
  color: var(--n-text-2);
  font-weight: 600;
  white-space: nowrap;
  text-decoration: none;
}
.n-tab:hover {
  color: var(--n-text);
  text-decoration: none;
}
.n-tab[aria-selected="true"],
.n-tab[aria-current="page"],
.n-tab.active {
  color: var(--n-accent-strong);
}
[data-bs-theme="dark"] .n-tab[aria-selected="true"],
[data-bs-theme="dark"] .n-tab[aria-current="page"],
[data-bs-theme="dark"] .n-tab.active {
  color: var(--n-link);
}
.n-tab[aria-selected="true"]::after,
.n-tab[aria-current="page"]::after,
.n-tab.active::after {
  content: "";
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: -1px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
}
.n-card > .n-tabs {
  padding: 0 12px;
}
.n-segment {
  display: inline-flex;
  gap: 2px;
  padding: 3px;
  border-radius: var(--n-r);
  background: var(--n-panel);
  border: 1px solid var(--n-border);
}
.n-segment > * {
  height: 32px;
  padding: 0 12px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--n-text-2);
  font-size: 13px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-decoration: none;
}
.n-segment > [aria-pressed="true"],
.n-segment > [aria-selected="true"],
.n-segment > .active {
  background: var(--n-surface);
  color: var(--n-text);
  box-shadow: var(--n-shadow-sm);
}
.n-sidenav {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 8px;
}
.n-sidenav a {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 40px;
  padding: 0 12px;
  border-radius: var(--n-r);
  color: var(--n-text-2);
  font-weight: 600;
  text-decoration: none;
}
.n-sidenav a:hover {
  background: var(--n-panel);
  color: var(--n-text);
}
.n-sidenav a[aria-current="page"] {
  background: var(--n-accent-soft);
  color: var(--n-accent-strong);
}
[data-bs-theme="dark"] .n-sidenav a[aria-current="page"] {
  color: var(--n-link);
}

/* ---------- Menus (button[data-n-menu] + .n-menu) ---------- */
.n-menu {
  position: fixed;
  z-index: 1060;
  min-width: 200px;
  max-width: min(320px, calc(100vw - 16px));
  padding: 6px;
  border: 1px solid var(--n-border);
  border-radius: 12px;
  background: var(--n-surface);
  box-shadow: var(--n-shadow-lg);
}
.n-menu-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 38px;
  padding: 0 10px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--n-text);
  font-size: 13.5px;
  font-weight: 500;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
}
.n-menu-item .n-i {
  color: var(--n-text-2);
}
.n-menu-item:hover,
.n-menu-item:focus-visible {
  background: var(--n-panel);
  outline: none;
  text-decoration: none;
}
.n-menu-item.danger,
.n-menu-item.danger .n-i {
  color: var(--n-danger);
}
.n-menu-item.danger:hover {
  background: var(--n-danger-soft);
}
.n-menu-sep {
  height: 1px;
  margin: 6px 4px;
  background: var(--n-border);
}
.n-menu-head {
  padding: 8px 10px 10px;
}
.n-menu form {
  margin: 0;
}

/* ---------- Dialogs (<dialog class="n-dialog">) ---------- */
dialog.n-dialog {
  width: min(520px, calc(100vw - 24px));
  max-height: calc(100dvh - 48px);
  padding: 0;
  border: 1px solid var(--n-border);
  border-radius: 18px;
  background: var(--n-surface);
  color: var(--n-text);
  box-shadow: var(--n-shadow-lg);
  overflow: hidden;
}
dialog.n-dialog[open] {
  display: flex;
  flex-direction: column;
  animation: n-pop 0.16s ease-out;
}
dialog.n-dialog.sm {
  width: min(420px, calc(100vw - 24px));
}
dialog.n-dialog.lg {
  width: min(760px, calc(100vw - 24px));
}
dialog.n-dialog.xl {
  width: min(1040px, calc(100vw - 24px));
}
dialog.n-dialog::backdrop {
  background: rgba(7, 20, 55, 0.45);
  -webkit-backdrop-filter: blur(2px);
  backdrop-filter: blur(2px);
}
.n-dialog-head {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: none;
  padding: 18px 20px 14px;
}
.n-dialog-head h2 {
  flex: 1;
  font-size: 17px;
}
.n-dialog-body {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 4px 20px 20px;
}
.n-dialog-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex: none;
  padding: 14px 20px;
  border-top: 1px solid var(--n-border);
  background: var(--n-panel);
}
.n-dialog > form {
  display: flex;
  flex-direction: column;
  min-height: 0;
  margin: 0;
}
.n-dialog-icon {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  margin-bottom: 12px;
  border-radius: 14px;
  background: var(--tone-soft, var(--n-accent-soft));
  color: var(--tone, var(--n-accent-strong));
}
.n-dialog.message .n-dialog-body {
  padding-top: 24px;
}
.n-dialog.message .n-dialog-body p {
  margin-top: 6px;
  color: var(--n-text-2);
}
@media (max-width: 575.98px) {
  dialog.n-dialog,
  dialog.n-dialog.lg,
  dialog.n-dialog.xl {
    width: 100vw;
    max-width: 100vw;
    max-height: 92dvh;
    margin: auto 0 0;
    border-radius: 18px 18px 0 0;
  }
}

/* ---------- Toasts ---------- */
.n-toasts {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 2000;
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: min(380px, calc(100vw - 32px));
  pointer-events: none;
}
.n-toast {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 12px 12px 14px;
  border: 1px solid var(--n-border);
  border-left: 4px solid var(--tone, var(--n-accent));
  border-radius: 12px;
  background: var(--n-surface);
  color: var(--n-text);
  box-shadow: var(--n-shadow-lg);
  font-size: 13.5px;
  pointer-events: auto;
  animation: n-slide 0.2s ease-out;
}
.n-toast > .n-i {
  margin-top: 1px;
  color: var(--tone, var(--n-accent));
}
.n-toast-body {
  flex: 1;
  min-width: 0;
  overflow-wrap: anywhere;
}
.n-toast-body b {
  display: block;
}
.n-toast-body span {
  color: var(--n-text-2);
}
.n-toast.leaving {
  opacity: 0;
  transform: translateX(16px);
  transition: opacity 0.2s, transform 0.2s;
}

/* ---------- Lists, description lists, misc ---------- */
.n-list {
  margin: 0;
  padding: 0;
  list-style: none;
}
.n-list-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 20px;
  border-bottom: 1px solid var(--n-border);
}
.n-list-item:last-child {
  border-bottom: 0;
}
a.n-list-item {
  color: inherit;
  text-decoration: none;
}
a.n-list-item:hover {
  background: var(--n-accent-softer);
}
.n-list-item.unread {
  background: var(--n-accent-softer);
}
.n-list-main {
  flex: 1;
  min-width: 0;
}
.n-list-main b {
  display: block;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.n-list-main span,
.n-list-main p {
  display: block;
  font-size: 13px;
  color: var(--n-text-2);
}
.n-list-meta {
  flex: none;
  font-size: 12px;
  color: var(--n-text-3);
  text-align: right;
}
.n-dl {
  display: grid;
  grid-template-columns: minmax(120px, 200px) minmax(0, 1fr);
  gap: 12px 20px;
  margin: 0;
}
.n-dl dt {
  color: var(--n-text-3);
  font-size: 13px;
  font-weight: 500;
}
.n-dl dd {
  margin: 0;
  font-weight: 500;
  overflow-wrap: anywhere;
}
@media (max-width: 575.98px) {
  .n-dl {
    grid-template-columns: minmax(0, 1fr);
    gap: 2px;
  }
  .n-dl dd {
    margin-bottom: 10px;
  }
}
.n-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 48px 24px;
  color: var(--n-text-2);
  text-align: center;
}
.n-empty .n-tile {
  width: 56px;
  height: 56px;
  margin-bottom: 4px;
  border-radius: 16px;
}
.n-empty b {
  font-size: 15px;
  color: var(--n-text);
}
.n-empty p {
  max-width: 420px;
  font-size: 13.5px;
}
.n-progress {
  height: 8px;
  overflow: hidden;
  border-radius: var(--n-pill);
  background: var(--n-panel);
  border: 1px solid var(--n-border);
}
.n-progress > span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--tone, var(--n-accent));
  transition: width 0.3s;
}
.n-spinner {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 2px solid var(--n-border-strong);
  border-top-color: var(--n-accent);
  border-radius: 50%;
  animation: n-spin 0.7s linear infinite;
  vertical-align: middle;
}
.n-spinner.lg {
  width: 32px;
  height: 32px;
  border-width: 3px;
}
.n-spinner.sm {
  width: 14px;
  height: 14px;
}
/* Wait spinner on icon buttons and menu items while their action runs (NUI.busy) */
.n-icon-btn[aria-busy="true"],
.n-menu-item[aria-busy="true"] {
  position: relative;
  pointer-events: none;
}
.n-icon-btn[aria-busy="true"] > * {
  visibility: hidden;
}
.n-icon-btn[aria-busy="true"]::after {
  content: "";
  position: absolute;
  inset: 0;
  margin: auto;
  width: 14px;
  height: 14px;
  border: 2px solid var(--n-text-3);
  border-right-color: transparent;
  border-radius: 50%;
  animation: n-spin 0.7s linear infinite;
}
.n-menu-item[aria-busy="true"] > svg {
  visibility: hidden;
}
.n-menu-item[aria-busy="true"]::before {
  content: "";
  position: absolute;
  width: 12px;
  height: 12px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: n-spin 0.7s linear infinite;
}
/* Page-wide "Working…" indicator while an action runs (NUI.activity) */
.n-activity {
  position: fixed;
  top: 14px;
  left: 50%;
  z-index: 2100;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px;
  border: 1px solid var(--n-border);
  border-radius: 999px;
  background: var(--n-surface);
  color: var(--n-text);
  font-size: 13px;
  font-weight: 500;
  box-shadow: var(--n-shadow);
  transform: translate(-50%, -8px);
  opacity: 0;
  pointer-events: none;
  transition:
    opacity 0.15s,
    transform 0.15s;
}
.n-activity.show {
  opacity: 1;
  transform: translate(-50%, 0);
}
html.n-working,
html.n-working * {
  cursor: progress !important;
}
@media (prefers-reduced-motion: reduce) {
  .n-activity {
    transition: none;
  }
}
.n-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 40px;
  color: var(--n-text-3);
}
.n-skeleton {
  border-radius: 8px;
  background: linear-gradient(90deg, var(--n-panel), var(--n-border), var(--n-panel));
  background-size: 200% 100%;
  animation: n-shimmer 1.2s infinite;
}
.n-kbd,
kbd {
  display: inline-block;
  min-width: 22px;
  padding: 1px 6px;
  border: 1px solid var(--n-border);
  border-bottom-width: 2px;
  border-radius: 6px;
  background: var(--n-panel);
  font-size: 12px;
  text-align: center;
}
.n-code {
  display: block;
  padding: 12px 14px;
  overflow-x: auto;
  border-radius: var(--n-r);
  background: var(--n-panel);
  border: 1px solid var(--n-border);
  font-family: var(--n-mono);
  font-size: 12.5px;
  white-space: pre-wrap;
}
.n-divider {
  height: 1px;
  margin: 4px 0;
  background: var(--n-border);
}
.n-timeline {
  position: relative;
  margin: 0;
  padding: 0;
  list-style: none;
}
.n-timeline li {
  position: relative;
  padding: 0 0 18px 28px;
}
.n-timeline li::before {
  content: "";
  position: absolute;
  left: 7px;
  top: 6px;
  bottom: -6px;
  width: 2px;
  background: var(--n-border);
}
.n-timeline li:last-child::before {
  display: none;
}
.n-timeline li::after {
  content: "";
  position: absolute;
  left: 2px;
  top: 4px;
  width: 12px;
  height: 12px;
  border: 2px solid var(--tone, var(--n-accent));
  border-radius: 50%;
  background: var(--n-surface);
}

/* ---------- Profile (Views/Settings/Profile.cshtml) ---------- */
/* Figma "profilePage" and "profileEdit": a header card with a brand banner (the sign-in mosaic, in a row) and the
   picture overlapping it, then the edit card with close, title and Save in its head. Settings links and account
   facts sit in the right rail. */
.n-profile-hero {
  overflow: hidden;
}
.n-profile-cover {
  display: grid;
  grid-template-columns: repeat(8, minmax(0, 1fr));
  align-items: center;
  gap: 12px;
  height: clamp(120px, 16vw, 180px);
  padding: 0 16px;
  overflow: hidden;
  background: var(--auth-art, var(--n-accent));
}
.n-profile-cover > span {
  display: grid;
  place-items: center;
  color: var(--auth-ink, var(--n-text));
}
.n-profile-cover .tile {
  aspect-ratio: 155 / 117;
  border-radius: 8px;
}
.n-profile-cover .disc {
  justify-self: center;
  width: 78%;
  aspect-ratio: 1;
  border-radius: 50%;
}
.n-profile-cover .n-i {
  width: 38%;
  height: auto;
  aspect-ratio: 1;
  stroke-width: 1.4;
}
.n-profile-cover .t-red { background: var(--auth-red, var(--n-danger)); color: #fff; }
.n-profile-cover .t-yellow { background: var(--auth-yellow, var(--n-warning-soft)); }
.n-profile-cover .t-gold { background: var(--auth-gold, var(--n-panel)); }
.n-profile-cover .t-cream { background: var(--auth-cream, var(--n-accent-soft)); }
.n-profile-cover .t-forest { background: var(--auth-forest, var(--n-navy)); color: var(--auth-yellow, #fff); }
@media (max-width: 575.98px) {
  .n-profile-cover {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
  .n-profile-cover > :nth-child(n + 5) {
    display: none;
  }
}
.n-profile-id {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 12px 20px;
  padding: 0 24px 4px;
}
.n-profile-photo {
  position: relative;
  flex: none;
  margin-top: -56px;
}
.n-profile-photo .n-avatar {
  width: 128px;
  height: 128px;
  padding: 4px;
  border: 3px solid var(--n-highlight);
  background: var(--n-surface);
  box-shadow: 0 0 0 4px var(--n-surface);
  font-size: 40px;
}
.n-profile-photo .n-avatar > img {
  border-radius: 50%;
}
/* initials sit on a soft disc inside the ring, like the picture does */
.n-profile-photo .n-avatar:not(:has(img)) {
  background: radial-gradient(circle, var(--n-accent-soft) 58px, transparent 59px) var(--n-surface);
}
.n-profile-photo-btn {
  position: absolute;
  right: 4px;
  bottom: 4px;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 3px solid var(--n-surface);
  border-radius: 50%;
  background: var(--n-accent);
  color: var(--n-on-accent);
  cursor: pointer;
}
.n-profile-photo-btn:hover {
  background: var(--n-accent-strong);
}
.n-profile-photo:has(input:focus-visible) .n-profile-photo-btn,
.n-profile-hero:has(#ProfilePicture:focus-visible) .n-profile-photo-btn {
  outline: 2px solid var(--n-accent);
  outline-offset: 2px;
}
.n-profile-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1 1 240px;
  min-width: 0;
  padding-top: 12px;
}
.n-profile-name {
  margin: 0;
  font-size: 22px;
  font-weight: 700;
  line-height: 1.3;
  color: var(--n-text);
  overflow-wrap: anywhere;
}
.n-profile-role {
  margin: 0;
  font-size: 14px;
  font-weight: 500;
  color: var(--n-link);
}
.n-profile-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 16px;
  margin: 6px 0 0;
  font-size: 12.5px;
  color: var(--n-text-2);
}
.n-profile-meta > span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  overflow-wrap: anywhere;
}
.n-profile-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.n-profile-upload {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 12px;
  padding: 12px 24px 20px;
}
@media (max-width: 575.98px) {
  .n-profile-id {
    padding-inline: 16px;
  }
  .n-profile-upload {
    padding-inline: 16px;
  }
  .n-profile-actions {
    width: 100%;
  }
  .n-profile-actions .n-btn {
    flex: 1;
  }
}
.n-profile-edit-head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--n-border);
}
.n-profile-edit-title {
  flex: 1;
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  color: var(--n-text);
}
.n-profile-edit-head .n-btn {
  min-width: 72px;
}
.n-notched .n-form-grid {
  gap: 24px 20px;
}
.n-notched .n-card-body {
  padding-top: 28px;
}
.n-notched .n-field .n-input[readonly] {
  background: var(--n-panel);
  color: var(--n-text-2);
}
.n-notched .n-field:has(.n-input[readonly]) > .n-label {
  background: linear-gradient(to bottom, var(--n-surface) 50%, var(--n-panel) 50%);
}
/* right rail: the Settings links as rows with round icon chips (Figma "Quick Action") */
.n-rail-nav > .n-card {
  border: 0;
  background: none;
  box-shadow: none;
}
.n-rail-nav .n-sidenav {
  gap: 4px;
  padding: 0;
}
.n-rail-nav .n-sidenav a {
  gap: 12px;
  height: 44px;
  padding: 0 6px;
  border-radius: var(--n-pill);
  font-weight: 500;
}
.n-rail-nav .n-sidenav a > .n-i:first-child {
  box-sizing: content-box;
  flex: none;
  padding: 8px;
  border-radius: 50%;
  background: var(--n-accent-soft);
  color: var(--n-accent-strong);
}
.n-rail-nav .n-sidenav a[aria-current="page"] {
  background: var(--n-surface);
  box-shadow: var(--n-shadow-sm);
}
.n-rail-nav .n-sidenav a[aria-current="page"] > .n-i:first-child {
  background: var(--n-accent);
  color: var(--n-on-accent);
}
.n-profile-facts {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 0;
  font-size: 13px;
}
.n-profile-facts dt {
  font-size: 12px;
  font-weight: 500;
  color: var(--n-text-3);
}
.n-profile-facts dd {
  margin: 0;
  color: var(--n-text);
}
/* Settings rail (Views/Settings/_SettingsRail.cshtml). Below 1200px the rail would fall under the page, so its blocks
   join the page column (display: contents): blocks marked .n-rail-lead (the Settings links, Policies' section list)
   move above the page, the rest (Profile's "Your account", Policies' recent changes) stay under it. The Settings
   links become a row of chips that scrolls sideways; .compact keeps them as chips at every width. */
.n-settings-rail.compact .n-sidenav {
  flex-direction: row;
  flex-wrap: wrap;
  gap: 6px;
}
.n-settings-rail.compact .n-sidenav a {
  flex: none;
  height: 34px;
  padding: 0 12px 0 3px;
  gap: 6px;
  background: var(--n-surface);
  box-shadow: var(--n-shadow-sm);
  font-size: 13px;
  white-space: nowrap;
}
.n-settings-rail.compact .n-sidenav a > .n-i:first-child {
  padding: 5px;
}
@media (max-width: 1199.98px) {
  .n-aside:has(.n-rail-lead) {
    display: contents;
  }
  .n-rail-lead {
    order: -1;
    min-width: 0;
  }
  .n-settings-rail .n-rail-head {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
  }
  .n-settings-rail .n-sidenav,
  .n-settings-rail.compact .n-sidenav {
    flex-direction: row;
    flex-wrap: nowrap;
    gap: 8px;
    margin: -4px;
    padding: 4px;
    overflow-x: auto;
    scrollbar-width: none;
  }
  .n-settings-rail .n-sidenav::-webkit-scrollbar {
    display: none;
  }
  .n-settings-rail .n-sidenav a,
  .n-settings-rail.compact .n-sidenav a {
    flex: none;
    height: 40px;
    padding: 0 14px 0 4px;
    gap: 8px;
    background: var(--n-surface);
    box-shadow: var(--n-shadow-sm);
    font-size: inherit;
    white-space: nowrap;
  }
  .n-settings-rail .n-sidenav a > .n-i:first-child {
    padding: 6px;
  }
  /* a long section list (Policies) above the page: wrapping chips, so it doesn't push the page far down */
  .n-rail-lead:not(.n-settings-rail) .n-sidenav {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 6px;
  }
  .n-rail-lead:not(.n-settings-rail) .n-sidenav a {
    flex: none;
    gap: 6px;
    height: auto;
    min-height: 34px;
    padding: 0 12px 0 3px;
    background: var(--n-surface);
    box-shadow: var(--n-shadow-sm);
    font-size: 13px;
  }
  .n-rail-lead:not(.n-settings-rail) .n-sidenav a > .n-i:first-child {
    padding: 5px;
  }
  .n-rail-lead:not(.n-settings-rail) .n-sidenav a > .n-badge {
    margin-left: 2px;
  }
}

/* ---------- Auth pages (Views/Shared/_Auth.cshtml) ---------- */
/* Split screen (Figma "Log In"): a brand panel with a mosaic of tiles and circles and the strapline on the left, the
   logo, form and footer line on the right. Below 992px only the right side shows. Spacing scales with the viewport
   (clamp), so it holds from 320px phones to wide desktops, and short screens tighten up instead of clipping.
   Mosaic colours: --auth-art, --auth-red, --auth-yellow, --auth-gold, --auth-cream, --auth-forest (oma-theme.css). */
.n-auth {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  min-height: 100vh;
  min-height: 100dvh;
  overflow-x: hidden;
  background: var(--n-canvas);
  color: var(--n-text);
}
.n-auth-art {
  display: none;
}
@media (min-width: 992px) {
  .n-auth {
    grid-template-columns: minmax(0, 49fr) minmax(0, 51fr);
  }
  .n-auth-art {
    position: sticky;
    top: 0;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 40px;
    height: 100vh;
    height: 100dvh;
    padding: clamp(32px, 6vh, 56px) clamp(28px, 3vw, 44px) clamp(40px, 8vh, 80px);
    overflow: hidden;
    background: var(--auth-art, var(--n-accent));
    color: #fff;
  }
}
.n-auth-mosaic {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px 0;
  width: min(100%, 620px);
}
.n-auth-mosaic > span {
  display: grid;
  place-items: center;
  overflow: hidden;
  color: var(--auth-ink, var(--n-text));
}
.n-auth-mosaic .tile {
  aspect-ratio: 155 / 117;
  border-radius: 8px;
}
.n-auth-mosaic .disc {
  justify-self: center;
  width: 75%;
  aspect-ratio: 1;
  border-radius: 50%;
}
.n-auth-mosaic .n-i {
  width: 36%;
  height: auto;
  aspect-ratio: 1;
  stroke-width: 1.4;
}
.n-auth-mosaic .disc .n-i {
  width: 44%;
}
.n-auth-mosaic img {
  width: 62%;
  height: auto;
}
.n-auth-mosaic .t-red { background: var(--auth-red, var(--n-danger)); color: #fff; }
.n-auth-mosaic .t-yellow { background: var(--auth-yellow, var(--n-warning-soft)); }
.n-auth-mosaic .t-gold { background: var(--auth-gold, var(--n-panel)); }
.n-auth-mosaic .t-cream { background: var(--auth-cream, var(--n-accent-soft)); }
.n-auth-mosaic .t-forest { background: var(--auth-forest, var(--n-navy)); color: var(--auth-yellow, #fff); }
.n-auth-mosaic .t-white { background: #fff; }
.n-auth-pitch {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: 540px;
  font-size: clamp(16px, 1.4vw, 20px);
  line-height: 1.5;
}
.n-auth-pitch-title {
  font-size: clamp(26px, 2.4vw, 34px);
  font-weight: 700;
  line-height: 1.25;
}
.n-auth-side {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.n-auth-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  /* "safe" keeps the top of a tall form reachable when it overflows a short screen */
  justify-content: safe center;
  padding:
    max(clamp(24px, 6vh, 56px), env(safe-area-inset-top))
    max(clamp(16px, 4vw, 24px), env(safe-area-inset-right))
    clamp(12px, 3vh, 24px)
    max(clamp(16px, 4vw, 24px), env(safe-area-inset-left));
}
.n-auth-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: clamp(12px, 2.5vh, 20px);
  border-radius: 12px;
  color: var(--n-text);
  text-decoration: none;
}
.n-auth-brand:hover {
  color: var(--n-text);
  text-decoration: none;
}
.n-auth-brand:focus-visible {
  outline: 2px solid var(--n-accent);
  outline-offset: 6px;
}
.n-auth-logo {
  display: block;
  width: 48px;
  height: 48px;
}
.n-auth-wordmark {
  font-size: 32px;
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.2;
}
.n-auth-card {
  width: 100%;
  max-width: 400px;
}
.n-auth-card h1 {
  font-size: clamp(20px, 5vw, 22px);
  letter-spacing: -0.01em;
  text-align: center;
}
.n-auth-card .n-page-sub {
  margin: 4px 0 clamp(20px, 4vw, 28px);
  font-size: 14px;
  font-weight: 500;
  text-align: center;
}
/* Fields with the label sitting on the top border (sign-in pages, and any card with .n-notched, e.g. Profile) */
.n-auth .n-form {
  gap: 20px;
}
:is(.n-auth, .n-notched) .n-field {
  position: relative;
  gap: 4px;
}
:is(.n-auth, .n-notched) .n-field > .n-label {
  position: absolute;
  top: -8px;
  left: 10px;
  z-index: 1;
  padding: 0 4px;
  background: var(--n-surface);
  font-size: 12px;
  font-weight: 500;
  line-height: 16px;
  color: var(--n-text-2);
}
:is(.n-auth, .n-notched) .n-field .n-input {
  min-height: 56px;
  padding: 14px 14px 12px;
  border: 2px solid var(--n-border);
  border-radius: 6px;
  background: var(--n-surface);
}
:is(.n-auth, .n-notched) .n-field .n-input:focus {
  border-color: var(--n-accent);
  box-shadow: none;
}
:is(.n-auth, .n-notched) .n-field:focus-within > .n-label {
  color: var(--n-accent-strong);
}
:is(.n-auth, .n-notched) .n-field .n-input-icon > .n-input {
  padding-left: 40px;
}
:is(.n-auth, .n-notched) .n-field .n-input-icon > .n-i {
  left: 14px;
}
/* the show/hide password button sits inside the field */
:is(.n-auth, .n-notched) .n-field .n-input-group {
  position: relative;
}
:is(.n-auth, .n-notched) .n-field .n-input-group > .n-input {
  padding-right: 52px;
  border-radius: 6px;
}
:is(.n-auth, .n-notched) .n-field .n-input-group > .n-btn.icon {
  position: absolute;
  top: 50%;
  right: 8px;
  margin: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  transform: translateY(-50%);
}
.n-auth .n-btn.block.lg {
  min-height: 52px;
  border-radius: 8px;
}
.n-auth-foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px 16px;
  padding:
    clamp(12px, 2.5vh, 20px)
    max(16px, env(safe-area-inset-right))
    max(clamp(16px, 3.5vh, 28px), env(safe-area-inset-bottom))
    max(16px, env(safe-area-inset-left));
  font-size: 12.5px;
  color: var(--n-text-3);
  text-align: center;
}
.n-auth-foot a {
  color: var(--n-text-2);
}
.n-auth-foot-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
/* phones */
@media (max-width: 575.98px) {
  /* 16px stops iOS zooming into a field on focus */
  .n-auth .n-input,
  .n-auth .n-select,
  .n-auth .n-textarea {
    font-size: 16px;
  }
  .n-auth-wordmark {
    font-size: 26px;
  }
}
/* very narrow phones */
@media (max-width: 359.98px) {
  .n-auth-main {
    padding-inline: 12px;
  }
}
/* short screens (landscape phones): smaller brand, less space */
@media (max-height: 560px) {
  .n-auth-logo {
    width: 36px;
    height: 36px;
  }
  .n-auth-wordmark {
    font-size: 24px;
  }
}

/* ---------- Store badges (Views/Shared/_AppBadges.cshtml) ---------- */
.n-badges {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}
.n-badges a {
  display: block;
  border-radius: 8px;
  line-height: 0;
  transition: transform 0.12s, box-shadow 0.12s;
}
.n-badges a:hover {
  transform: translateY(-1px);
  box-shadow: var(--n-shadow);
}
.n-badges img {
  display: block;
  width: auto;
  height: 44px;
}
.n-badges.compact img {
  height: 34px;
}
/* Desktop app badge, drawn to match the store badges (black, grey hairline, logo + two-line label) */
.n-badges a.n-desktop-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 44px;
  padding: 0 14px 0 11px;
  border: 1px solid #a6a6a6;
  border-radius: 8px;
  background: #000;
  color: #fff;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
}
.n-desktop-badge-logo {
  flex: none;
  width: 24px;
  height: 24px;
}
.n-desktop-badge-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.n-desktop-badge-text small {
  font-size: 10px;
  letter-spacing: 0.02em;
}
.n-desktop-badge-text b {
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.n-badges.compact a.n-desktop-badge {
  gap: 6px;
  height: 34px;
  padding: 0 11px 0 8px;
  border-radius: 6px;
}
.n-badges.compact .n-desktop-badge-logo {
  width: 19px;
  height: 19px;
}
.n-badges.compact .n-desktop-badge-text small {
  font-size: 8px;
}
.n-badges.compact .n-desktop-badge-text b {
  font-size: 13px;
}
/* Already in the desktop app: no need to offer it */
.nics-desktop .n-desktop-badge {
  display: none !important;
}
.n-app-card {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 20px;
  padding: 20px 24px;
}
.n-app-card-text {
  flex: 1;
  min-width: 220px;
}
.n-app-card-text p {
  margin-top: 2px;
  color: var(--n-text-2);
  font-size: 13.5px;
}

/* ---------- Text helpers ---------- */
.n-muted {
  color: var(--n-text-3);
}
.n-soft {
  color: var(--n-text-2);
}
.n-small {
  font-size: 12.5px;
}
.n-strong {
  font-weight: 700;
}
.n-mono {
  font-family: var(--n-mono);
  font-size: 0.92em;
}
.n-danger-text {
  color: var(--n-danger);
}
.n-success-text {
  color: var(--n-success);
}
.n-warning-text {
  color: var(--n-warning);
}
.n-truncate {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.n-nowrap {
  white-space: nowrap;
}
.n-center {
  text-align: center;
}
.n-right {
  text-align: right;
}
.n-sr {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.n-mt {
  margin-top: 16px;
}
.n-mt-lg {
  margin-top: 24px;
}
.n-mb {
  margin-bottom: 16px;
}
.n-mb-lg {
  margin-bottom: 24px;
}
.n-w-full {
  width: 100%;
}

/* ---------- Compatibility helpers toggled by chat / mail / call scripts ---------- */
.d-none {
  display: none !important;
}
.d-flex {
  display: flex !important;
}
.d-block {
  display: block !important;
}
.flex-column {
  flex-direction: column !important;
}
.align-items-center {
  align-items: center !important;
}
.justify-content-between {
  justify-content: space-between !important;
}
.justify-content-center {
  justify-content: center !important;
}
.flex-wrap {
  flex-wrap: wrap !important;
}
.gap-1 {
  gap: 4px !important;
}
.gap-2 {
  gap: 8px !important;
}
.gap-3 {
  gap: 12px !important;
}
.gap-4 {
  gap: 16px !important;
}
.w-100 {
  width: 100% !important;
}

/* ---------- Motion ---------- */
@keyframes n-spin {
  to {
    transform: rotate(360deg);
  }
}
@keyframes n-pop {
  from {
    opacity: 0;
    transform: translateY(8px) scale(0.98);
  }
}
@keyframes n-slide {
  from {
    opacity: 0;
    transform: translateX(16px);
  }
}
@keyframes n-shimmer {
  to {
    background-position: -200% 0;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

/* ---------- Print ---------- */
@media print {
  .n-sidebar,
  .n-topbar,
  .n-footer,
  .n-feedback-btn,
  .n-page-actions,
  .n-toasts {
    display: none !important;
  }
  .n-shell {
    display: block;
  }
  body {
    background: #fff;
  }
  .n-card {
    box-shadow: none;
  }
}

/* ---------- Planned maintenance notice (_Layout; Settings › Policies › Maintenance) ---------- */
.n-maint {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 12px 24px 0;
}
.n-maint .n-alert {
  align-items: center;
  padding: 10px 12px 10px 16px;
}
.n-maint .n-alert-title {
  display: inline;
  margin: 0 6px 0 0;
}
@media (max-width: 767.98px) {
  .n-maint {
    padding: 10px 12px 0;
  }
}

/* ---------- Standalone pages (Views/Shared/_Standalone.cshtml) ---------- */
/* Full-page states outside the app shell: logo top left, the page centred on the canvas, a footer line. */
.n-solo {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;
  overflow-x: hidden;
  background:
    radial-gradient(ellipse 70% 55% at 50% -10%, var(--n-accent-soft) 0%, transparent 70%),
    radial-gradient(circle at 1px 1px, var(--n-border) 1px, transparent 0) 0 0 / 24px 24px,
    var(--n-canvas);
}
.n-solo-head {
  padding:
    max(clamp(16px, 3vh, 28px), env(safe-area-inset-top))
    max(clamp(16px, 4vw, 40px), env(safe-area-inset-right))
    0
    max(clamp(16px, 4vw, 40px), env(safe-area-inset-left));
}
.n-solo-brand {
  display: inline-flex;
  border-radius: 8px;
}
.n-solo-brand:focus-visible {
  outline: 2px solid var(--n-accent);
  outline-offset: 6px;
}
.n-solo-brand img {
  display: block;
  width: auto;
  height: clamp(30px, 5vh, 40px);
}
[data-bs-theme="dark"] .n-solo-brand .n-logo-dark {
  display: block !important;
}
.n-solo-main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  justify-content: safe center;
  padding: clamp(24px, 6vh, 64px) max(16px, env(safe-area-inset-right)) clamp(24px, 6vh, 64px) max(16px, env(safe-area-inset-left));
}
.n-solo-foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px 16px;
  padding: 16px 16px max(24px, env(safe-area-inset-bottom));
  font-size: 12.5px;
  color: var(--n-text-3);
}
.n-solo-foot-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

/* ---------- Page not found (Views/Error/NotFound.cshtml) ---------- */
.n-404 {
  display: grid;
  grid-template-columns: minmax(220px, 340px) minmax(0, 520px);
  align-items: center;
  gap: clamp(32px, 6vw, 80px);
  width: 100%;
  max-width: 980px;
}
.n-404-art {
  color: var(--n-accent);
}
.n-404-art svg {
  display: block;
  width: 100%;
  height: auto;
}
.n-404-sweep {
  transform-origin: 160px 160px;
  animation: n-404-spin 6s linear infinite;
}
.n-404-pulse {
  transform-origin: 160px 160px;
  animation: n-404-pulse 2.4s ease-out infinite;
}
@keyframes n-404-spin {
  to {
    transform: rotate(-360deg);
  }
}
@keyframes n-404-pulse {
  0% {
    transform: scale(0.8);
    opacity: 1;
  }
  100% {
    transform: scale(1.9);
    opacity: 0;
  }
}
@media (prefers-reduced-motion: reduce) {
  .n-404-sweep,
  .n-404-pulse {
    animation: none;
  }
}
.n-404-code {
  display: inline-block;
  padding: 4px 12px;
  border-radius: var(--n-pill);
  background: var(--n-accent-soft);
  color: var(--n-accent-strong);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
[data-bs-theme="dark"] .n-404-code {
  color: var(--n-link);
}
.n-404-title {
  margin-top: 16px;
  font-size: clamp(28px, 4.4vw, 44px);
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1.12;
}
.n-404-lead {
  margin-top: 14px;
  max-width: 46ch;
  font-size: clamp(15px, 1.6vw, 16.5px);
  line-height: 1.6;
  color: var(--n-text-2);
}
.n-404-path {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  max-width: 100%;
  margin-top: 18px;
  padding: 7px 12px;
  border: 1px solid var(--n-border);
  border-radius: var(--n-r);
  background: var(--n-surface);
  color: var(--n-text-3);
}
.n-404-path code {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: var(--n-mono);
  font-size: 13px;
  color: var(--n-text-2);
}
.n-404-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}
.n-404-links {
  margin-top: 36px;
  padding-top: 24px;
  border-top: 1px solid var(--n-border);
}
.n-404-links-title {
  margin-bottom: 12px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--n-text-3);
}
.n-404-links ul {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding: 0;
  list-style: none;
}
.n-404-links a {
  display: flex;
  align-items: center;
  gap: 12px;
  height: 100%;
  padding: 12px;
  border: 1px solid var(--n-border);
  border-radius: 12px;
  background: var(--n-surface);
  color: var(--n-text);
  box-shadow: var(--n-shadow-sm);
  transition: border-color 0.15s, box-shadow 0.15s, transform 0.15s;
}
.n-404-links a:hover {
  border-color: var(--n-accent);
  box-shadow: var(--n-shadow);
  text-decoration: none;
  transform: translateY(-1px);
}
.n-404-links a:focus-visible {
  outline: 2px solid var(--n-accent);
  outline-offset: 2px;
}
.n-404-links-icon {
  display: grid;
  place-items: center;
  flex: none;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--n-accent-soft);
  color: var(--n-accent);
}
.n-404-links-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
  flex: 1;
}
.n-404-links-text b {
  font-weight: 600;
}
.n-404-links-text span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12.5px;
  color: var(--n-text-3);
}
.n-404-links-go {
  color: var(--n-text-3);
  transition: transform 0.15s, color 0.15s;
}
.n-404-links a:hover .n-404-links-go {
  color: var(--n-accent);
  transform: translateX(2px);
}
.n-404-ref {
  margin-top: 28px;
  font-size: 12.5px;
  color: var(--n-text-3);
}
.n-404-ref code {
  font-family: var(--n-mono);
  color: var(--n-text-2);
  word-break: break-all;
}
/* tablets and phones: one centred column, smaller artwork on top */
@media (max-width: 860px) {
  .n-404 {
    grid-template-columns: minmax(0, 520px);
    justify-content: center;
    gap: 8px;
    text-align: center;
  }
  .n-404-art {
    width: clamp(160px, 42vw, 240px);
    margin: 0 auto;
  }
  .n-404-lead {
    margin-inline: auto;
  }
  .n-404-actions {
    justify-content: center;
  }
  .n-404-links a {
    text-align: left;
  }
}
@media (max-width: 479.98px) {
  .n-404-actions .n-btn {
    flex: 1 1 100%;
  }
  .n-404-links ul {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ---------- Clan and Palace feed (dashboard: wwwroot/js/oma-feed.js; reports: Views/FeedReports) ---------- */
.of-feed {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100%;
}
.of-stack {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.of-stack:empty {
  display: none;
}
.of-tabs-card {
  padding: 0 8px;
}
.of-tabs-card .n-tabs {
  border-bottom: 0;
}
.of-note {
  margin: 0;
  padding: 12px 4px;
  color: var(--n-text-2);
  font-size: 13.5px;
  text-align: center;
}
.of-note .n-btn {
  margin-inline-start: 6px;
}
.of-fresh {
  position: sticky;
  top: 12px;
  z-index: 5;
  align-self: center;
  box-shadow: var(--n-shadow);
}
.of-fresh[hidden] {
  display: none;
}
.of-readonly {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 10px 14px;
  border-radius: var(--n-r);
  background: var(--n-panel);
  color: var(--n-text-2);
  font-size: 13px;
}
/* composer */
.of-composer {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 16px;
}
.of-compose-row {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}
.of-compose-text {
  flex: 1;
  min-width: 0;
  min-height: 56px;
  resize: vertical;
}
.of-compose-foot {
  display: flex;
  align-items: center;
  gap: 10px;
}
.of-compose-foot .of-count {
  flex: 1;
  font-size: 12.5px;
  text-align: end;
}
.of-previews {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(96px, 1fr));
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.of-preview {
  position: relative;
  aspect-ratio: 1;
  overflow: hidden;
  border-radius: var(--n-r);
  background: var(--n-panel);
}
.of-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.of-remove {
  position: absolute;
  top: 4px;
  inset-inline-end: 4px;
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border: 0;
  border-radius: 50%;
  background: rgba(7, 20, 55, 0.72);
  color: #fff;
  cursor: pointer;
}
.of-remove:hover {
  background: var(--n-danger);
}
/* post card */
.of-post {
  padding: 16px 16px 8px;
}
.of-post.is-hidden {
  border-style: dashed;
}
.of-head {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}
.of-who {
  flex: 1;
  min-width: 0;
}
.of-name-row {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}
.of-name {
  color: var(--n-text);
  font-size: 15px;
}
.of-verified {
  display: inline-flex;
  flex: none;
  color: var(--n-accent);
}
.of-sub {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  color: var(--n-text-3);
  font-size: 12.5px;
}
.of-tools {
  display: flex;
  flex: none;
  align-items: center;
  gap: 6px;
}
.of-text {
  margin: 12px 0 0;
  color: var(--n-text);
  line-height: 1.5;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.of-hidden-note {
  margin: 12px 0 0;
  padding: 8px 12px;
  border-radius: var(--n-r);
  background: var(--n-danger-soft);
  color: var(--n-danger-strong);
  font-size: 13px;
  overflow-wrap: anywhere;
}
[data-bs-theme="dark"] .of-hidden-note {
  color: var(--n-text);
}
.of-post.is-hidden .of-text,
.of-post.is-hidden .of-photos {
  opacity: 0.65;
}
.of-photos {
  display: grid;
  gap: 4px;
  margin-top: 12px;
  overflow: hidden;
  border-radius: 12px;
}
.of-photos.n1 {
  grid-template-columns: minmax(0, 1fr);
}
.of-photos.n2,
.of-photos.n3,
.of-photos.n4 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.of-photo {
  display: block;
  overflow: hidden;
  background: var(--n-panel);
  aspect-ratio: 4 / 3;
}
.of-photos.n1 .of-photo {
  aspect-ratio: 16 / 9;
  max-height: 440px;
}
/* Several photos: rows of a fixed, modest height, so a post never fills the whole screen */
.of-photos.n2 .of-photo,
.of-photos.n3 .of-photo,
.of-photos.n4 .of-photo {
  aspect-ratio: auto;
  height: clamp(140px, 16vw, 220px);
}
.of-photos.n3 .of-photo:first-child {
  grid-row: span 2;
  height: auto;
}
.of-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.2s;
}
.of-photo:hover img {
  transform: scale(1.03);
}
.of-actions {
  display: flex;
  gap: 4px;
  margin: 10px -8px 0;
  padding-top: 6px;
  border-top: 1px solid var(--n-border);
}
.of-act {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 40px;
  padding: 0 12px;
  border: 0;
  border-radius: var(--n-r);
  background: transparent;
  color: var(--n-text-2);
  font-size: 13.5px;
  font-weight: 600;
  cursor: pointer;
}
.of-act:hover {
  background: var(--n-panel);
  color: var(--n-text);
}
.of-act.on {
  color: var(--n-accent-strong);
}
[data-bs-theme="dark"] .of-act.on {
  color: var(--n-link);
}
.of-act[aria-label^="Unlike"] .n-i {
  fill: currentColor;
  color: var(--n-danger);
}
.of-act[aria-label^="Unlike"] {
  color: var(--n-danger);
}
/* comments */
.of-comments {
  margin: 0 -8px;
  padding: 8px 8px 8px;
  border-top: 1px solid var(--n-border);
}
.of-comment-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 0 0 12px;
  padding: 0;
  list-style: none;
}
.of-comment {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}
.of-comment-body {
  flex: 1;
  min-width: 0;
}
.of-bubble {
  display: inline-block;
  max-width: 100%;
  padding: 8px 12px;
  border-radius: 14px;
  background: var(--n-panel);
}
.of-bubble .of-name-row b {
  font-size: 13.5px;
}
.of-bubble .of-text {
  margin-top: 2px;
  font-size: 14px;
}
.of-comment .of-sub {
  margin: 2px 0 0 12px;
}
.of-comment.is-hidden .of-bubble {
  opacity: 0.65;
}
.of-comment-form {
  display: flex;
  gap: 8px;
}
.of-comment-form .n-input {
  flex: 1;
  min-width: 0;
}
.of-empty {
  padding: 32px 16px;
}
@media (max-width: 575.98px) {
  .of-post {
    padding: 14px 12px 6px;
  }
  .of-composer {
    padding: 12px;
  }
  .of-comment .n-icon-btn {
    margin-top: 2px;
  }
}
/* Administration › Feed reports */
.fr-card .n-card-body {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.fr-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 10px;
}
.fr-quote {
  margin: 0;
  padding: 10px 14px;
  border-inline-start: 3px solid var(--n-border-strong);
  border-radius: 0 var(--n-r) var(--n-r) 0;
  background: var(--n-panel);
  color: var(--n-text);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.fr-reasons {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin: 0;
  padding-inline-start: 18px;
  color: var(--n-text-2);
  font-size: 13.5px;
  overflow-wrap: anywhere;
}
.fr-foot {
  flex-wrap: wrap;
  gap: 8px;
}
