/*
 * ARBS production stylesheet — generated file.
 * Source of truth: static/arbs/css/ modules.
 * Rebuild with: python scripts/build_css.py
 * Do not edit this bundle directly.
 */

/* ===== BEGIN base.css ===== */
/*
 * ARBS stylesheet: base.css
 * Purpose: Global design tokens, reset, typography and low-level utilities.
 * Architecture: Loaded first. Do not place page-specific selectors here.
 */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;500;600;700;800&display=swap');
 :root {
   color-scheme: light;
   --font-sans: "Outfit", Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
   --brand: #0f8a78;
   --brand-hover: #0b7163;
   --brand-deep: #11584d;
   --brand-soft: #e8f7f3;
   --brand-softer: #f3fbf9;
   --button-primary: #0f8a78;
   --button-primary-hover: #0b7163;
   --button-primary-focus: #b8e8df;
   --accent: #14b8a6;
   --canvas: #f4f7f6;
   --surface: #ffffff;
   --surface-2: #f8faf9;
   --surface-soft: var(--surface-2);
   --surface-3: #eef3f1;
   --text: #17211e;
   --text-strong: #0e1714;
   --muted: #66756f;
   --muted-2: #8a9691;
   --border: #dce6e2;
   --border-strong: #cbd9d4;
   --sidebar: #173e34;
   --sidebar-hover: #225247;
   --sidebar-active: #0f8a78;
   --sidebar-text: #e8f1ee;
   --sidebar-muted: #a8beb7;
   --success: #027a48;
   --success-strong: #12b76a;
   --success-soft: #ecfdf3;
   --success-border: #a6f4c5;
   --warning: #b54708;
   --warning-strong: #f79009;
   --warning-soft: #fffaeb;
   --warning-border: #fedf89;
   --danger: #b42318;
   --danger-strong: #f04438;
   --danger-hover: #d92d20;
   --danger-soft: #fef3f2;
   --danger-border: #fecdca;
   --info: #0f766e;
   --info-strong: #0f8a78;
   --info-soft: #eefaf7;
   --info-border: #9edbd0;
   --shadow-sm: 0 1px 2px rgba(16, 38, 31, .04);
   --shadow-md: 0 8px 28px rgba(16, 38, 31, .07);
   --shadow-lg: 0 20px 50px rgba(16, 38, 31, .13);
   --radius-sm: 8px;
   --radius: 12px;
   --radius-lg: 18px;
   --sidebar-width: 280px;
   --sidebar-collapsed-width: 86px;
   --topbar-height: 76px;

}
 html.dark {
   color-scheme: dark;
   --canvas: #101a17;
   --surface: #15211d;
   --surface-2: #192822;
   --surface-3: #20312b;
   --text: #e6edf5;
   --text-strong: #ffffff;
   --muted: #aab7c8;
   --muted-2: #7e8da1;
   --border: #30443c;
   --border-strong: #40584f;
   --brand-soft: #123d39;
   --brand-softer: #102d2b;
   --success-soft: #0b2e1f;
   --success-border: #027a48;
   --warning-soft: #3b2608;
   --warning-border: #b54708;
   --danger-soft: #3b1513;
   --danger-border: #b42318;
   --info-soft: #102f2c;
   --info-border: #0f766e;
   --shadow-sm: 0 1px 2px rgba(0, 0, 0, .18);
   --shadow-md: 0 10px 30px rgba(0, 0, 0, .2);
   --shadow-lg: 0 22px 60px rgba(0, 0, 0, .32);

}
 * {
   box-sizing: border-box;

}
 html {
   min-height: 100%;
   background: var(--canvas);

}
 body {
   margin: 0;
   min-height: 100vh;
   font-family: var(--font-sans);
   font-size: 15px;
   line-height: 1.55;
   color: var(--text);
   background: var(--canvas);
   -webkit-font-smoothing: antialiased;

}
 a {
   color: inherit;

}
 button, input, select, textarea {
   font: inherit;

}
 button, a {
   -webkit-tap-highlight-color: transparent;

}
 [x-cloak] {
   display: none !important;

}
 .sr-only {
   position: absolute !important;
   width: 1px;
   height: 1px;
   padding: 0;
   margin: -1px;
   overflow: hidden;
   clip: rect(0,0,0,0);
   white-space: nowrap;
   border: 0;

}

[hidden] {
   display: none !important;

}

@media (max-width: 760px) {
  body {
    font-size: 14px;
  }
}
/* ===== END base.css ===== */

/* ===== BEGIN shell.css ===== */
/*
 * ARBS stylesheet: shell.css
 * Purpose: Authenticated application shell, sidebar, topbar and page viewport.
 * Architecture: Shell-only selectors and shell breakpoints.
 */

.app-shell {
   min-height: 100vh;
   display: grid;
   grid-template-columns: var(--sidebar-width) minmax(0, 1fr);
   transition: grid-template-columns .2s ease;

}
 .app-shell.sidebar-collapsed {
   grid-template-columns: var(--sidebar-collapsed-width) minmax(0, 1fr);

}
 .sidebar {
   position: sticky;
   top: 0;
   z-index: 40;
   height: 100vh;
   display: flex;
   flex-direction: column;
   overflow: hidden;
   padding: 18px 14px 14px;
   background: var(--sidebar);
   color: var(--sidebar-text);
   border-right: 1px solid rgba(255,255,255,.07);

}
 .sidebar-header {
   display: flex;
   align-items: center;
   justify-content: space-between;
   min-height: 54px;
   gap: 8px;
   margin-bottom: 12px;

}
 .brand {
   min-width: 0;
   display: flex;
   align-items: center;
   gap: 11px;

}
 .brand-mark {
   flex: none;
   width: 44px;
   height: 44px;
   display: grid;
   place-items: center;
   border-radius: 12px;
   background: linear-gradient(145deg, #18b6a4, #0f8a78);
   color: white;
   text-decoration: none;
   font-weight: 800;
   font-size: 16px;
   box-shadow: 0 8px 20px rgba(5, 30, 25, .2);

}
 .brand-mark.large {
   width: 58px;
   height: 58px;
   border-radius: 16px;
   font-size: 20px;

}
 .brand-copy {
   min-width: 0;
   display: grid;
   text-decoration: none;
   line-height: 1.25;

}
 .brand-copy strong {
   font-size: 16px;
   color: #fff;
   white-space: nowrap;

}
 .brand-copy small {
   color: var(--sidebar-muted);
   font-size: 12px;
   white-space: nowrap;
   overflow: hidden;
   text-overflow: ellipsis;

}
 .brand-tagline {
   margin-top: 2px;
   font-style: italic;

}
 .sidebar-collapse {
   flex: none;
   width: 32px;
   height: 32px;
   display: grid;
   place-items: center;
   border: 1px solid rgba(255,255,255,.12);
   border-radius: 9px;
   background: rgba(255,255,255,.055);
   color: #dbe9e4;
   cursor: pointer;

}
 .sidebar-collapse:hover {
   background: rgba(255,255,255,.1);

}
 .nav-list {
   overflow-y: auto;
   overflow-x: hidden;
   padding: 2px 0 18px;
   scrollbar-width: thin;

}
 .nav-heading {
   margin: 18px 10px 7px;
   color: #78968c;
   text-transform: uppercase;
   letter-spacing: .11em;
   font-size: 10px;
   font-weight: 800;
   white-space: nowrap;

}
 .nav-item {
   min-height: 44px;
   display: flex;
   align-items: center;
   gap: 12px;
   padding: 9px 11px;
   margin: 2px 0;
   border-radius: 10px;
   color: #cbdcd6;
   text-decoration: none;
   font-weight: 600;
   font-size: 14px;
   white-space: nowrap;
   transition: background .15s, color .15s, transform .15s;

}
 .nav-item:hover {
   color: #fff;
   background: var(--sidebar-hover);

}
 .nav-item.active {
   color: #fff;
   background: var(--sidebar-active);
   box-shadow: 0 7px 18px rgba(7, 78, 68, .24);

}
 .nav-icon {
   flex: none;
   width: 22px;
   text-align: center;
   color: inherit;
   font-size: 17px;

}
 .nav-icon svg {
   display: block;
   width: 20px;
   height: 20px;
   margin: 0 auto;
   overflow: visible;

}
 .nav-label {
   min-width: 0;
   overflow: hidden;
   text-overflow: ellipsis;

}
 .sidebar-panels {
   display: grid;
   gap: 8px;
   margin-top: auto;

}
 .sidebar-panel {
   display: grid;
   grid-template-columns: 34px minmax(0,1fr);
   align-items: center;
   gap: 10px;
   padding: 10px;
   border: 1px solid rgba(255,255,255,.08);
   border-radius: 11px;
   background: rgba(255,255,255,.045);
   text-decoration: none;

}
 .sidebar-panel:hover {
   background: rgba(255,255,255,.085);

}
 .panel-icon {
   width: 34px;
   height: 34px;
   display: grid;
   place-items: center;
   border-radius: 9px;
   background: rgba(20,184,166,.16);
   color: #7ee7da;
   font-weight: 800;

}
 .emergency-sidebar-card .panel-icon {
   background: rgba(248,113,113,.13);
   color: #fca5a5;

}
 .panel-copy {
   min-width: 0;
   display: grid;
   line-height: 1.25;

}
 .panel-copy small {
   color: #77978c;
   font-size: 9px;
   font-weight: 800;
   letter-spacing: .09em;
   text-transform: uppercase;

}
 .panel-copy strong {
   color: #fff;
   font-size: 12px;
   margin: 2px 0;
   overflow: hidden;
   text-overflow: ellipsis;
   white-space: nowrap;

}
 .panel-copy em {
   color: #a9bdb6;
   font-size: 10px;
   font-style: normal;
   overflow: hidden;
   text-overflow: ellipsis;
   white-space: nowrap;

}
 .sidebar-bottom {
   padding-top: 9px;

}
 .sidebar-credit {
   display: block;
   padding: 8px 10px 0;
   color: #87a299;
   font-size: 10px;

}
 .developer-credit {
   text-decoration: none;

}
 .developer-credit-wrap {
   display: inline-flex;
   align-items: center;
   flex-wrap: wrap;
   justify-content: center;
   gap: 6px;

}
 .developer-contact-link {
   color: inherit;
   font-weight: 700;
   text-decoration: none;

}
 .developer-contact-link:hover, .developer-contact-link:focus {
   text-decoration: underline;

}
 .developer-heart {
   color: #ef5964;

}
 .sidebar-collapsed .brand-copy, .sidebar-collapsed .nav-label, .sidebar-collapsed .nav-heading, .sidebar-collapsed .sidebar-panels, .sidebar-collapsed .sidebar-credit {
   display: none;

}
 .sidebar-collapsed .sidebar {
   padding-inline: 12px;

}
 .sidebar-collapsed .sidebar-header {
   justify-content: center;
   flex-wrap: wrap;

}
 .sidebar-collapsed .nav-item {
   justify-content: center;
   padding-inline: 8px;

}
 .sidebar-collapsed .nav-icon {
   width: 24px;

}
 .main-area {
   min-width: 0;

}
 .topbar {
   position: sticky;
   top: 0;
   z-index: 30;
   height: var(--topbar-height);
   display: flex;
   align-items: center;
   justify-content: space-between;
   padding: 0 26px;
   background: color-mix(in srgb, var(--surface) 94%, transparent);
   backdrop-filter: blur(14px);
   border-bottom: 1px solid var(--border);

}
 .topbar-left, .topbar-actions {
   display: flex;
   align-items: center;

}
 .topbar-left {
   min-width: 0;
   gap: 12px;

}
 .topbar-actions {
   margin-left: auto;
   gap: 9px;

}
 .menu-button {
   display: none;
   width: 40px;
   height: 40px;
   place-items: center;
   border: 1px solid var(--border);
   border-radius: 10px;
   background: var(--surface);
   color: var(--text);
   cursor: pointer;

}
 .page-identity {
   min-width: 0;

}
 .breadcrumb {
   display: flex;
   align-items: center;
   flex-wrap: wrap;
   gap: 7px;
   margin: 0 0 2px;
   color: var(--muted);
   font-size: 12px;

}
 .breadcrumb a {
   color: var(--brand);
   text-decoration: none;

}
 .page-identity h1 {
   margin: 0;
   color: var(--text-strong);
   font-size: 22px;
   line-height: 1.2;
   letter-spacing: -.025em;

}
 .icon-button {
   width: 40px;
   height: 40px;
   display: grid;
   place-items: center;
   position: relative;
   border: 1px solid var(--border);
   border-radius: 10px;
   background: var(--surface);
   color: var(--text);
   text-decoration: none;
   cursor: pointer;

}
 .icon-button:hover {
   border-color: var(--brand);
   color: var(--brand);
   background: var(--brand-softer);

}
 .notification-button > span {
   position: absolute;
   top: -5px;
   right: -5px;
   min-width: 19px;
   height: 19px;
   padding: 0 4px;
   display: grid;
   place-items: center;
   border: 2px solid var(--surface);
   border-radius: 999px;
   background: #dc3545;
   color: white;
   font-size: 10px;
   font-weight: 800;

}
 .profile-menu {
   position: relative;

}
 .user-chip {
   display: flex;
   align-items: center;
   gap: 9px;
   padding: 4px 7px;
   border: 0;
   border-radius: 10px;
   background: transparent;
   color: var(--text);
   cursor: pointer;

}
 .user-chip:hover {
   background: var(--surface-2);

}
 .avatar {
   flex: none;
   width: 39px;
   height: 39px;
   display: grid;
   place-items: center;
   border-radius: 50%;
   background: var(--brand-soft);
   color: var(--brand-deep);
   font-weight: 800;

}
 .user-copy {
   min-width: 0;
   display: grid;
   text-align: left;
   line-height: 1.25;

}
 .user-copy strong {
   color: var(--text-strong);
   font-size: 13px;
   white-space: nowrap;

}
 .user-copy small {
   color: var(--muted);
   font-size: 11px;

}
 .chevron {
   color: var(--muted);

}
 .profile-dropdown {
   position: absolute;
   top: calc(100% + 9px);
   right: 0;
   z-index: 60;
   width: 225px;
   padding: 7px;
   border: 1px solid var(--border);
   border-radius: 12px;
   background: var(--surface);
   box-shadow: var(--shadow-lg);

}
 .profile-dropdown a, .profile-dropdown button {
   width: 100%;
   display: block;
   padding: 10px 11px;
   border: 0;
   border-radius: 8px;
   background: transparent;
   color: var(--text);
   text-align: left;
   text-decoration: none;
   cursor: pointer;

}
 .profile-dropdown a:hover, .profile-dropdown button:hover {
   background: var(--surface-2);

}
 .page-content {
   width: 100%;
   max-width: 1760px;
   padding: 26px 28px 42px;

}
 .mobile-backdrop {
   display: none;

}

@media (max-width: 900px) {
  .app-shell,
  .app-shell.sidebar-collapsed {
    display: block;
  }
  .sidebar {
    position: fixed;
    left: 0;
    top: 0;
    width: var(--sidebar-width);
    transform: translateX(-105%);
    transition: transform .22s ease;
    box-shadow: var(--shadow-lg);
  }
  .sidebar.open {
    transform: translateX(0);
  }
  .sidebar-collapse {
    display: none;
  }
  .mobile-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 35;
    background: rgba(5, 15, 12, .58);
  }
  .menu-button {
    display: grid;
  }
  .topbar {
    padding-inline: 18px;
  }
  .page-content {
    padding: 22px 18px 36px;
  }
}

@media (max-width: 760px) {
  .topbar {
    height: 68px;
    padding-inline: 13px;
  }
  .page-content {
    padding: 16px 12px 30px;
  }
  .page-identity h1 {
    font-size: 18px;
  }
  .breadcrumb,
  .user-copy,
  .chevron {
    display: none;
  }
}
/* ===== END shell.css ===== */

/* ===== BEGIN components/layout.css ===== */
/*
 * ARBS stylesheet: components/layout.css
 * Purpose: Shared page headings, content composition, detail lists and spacing utilities.
 * Architecture: Structural layout primitives only; no domain-specific page selectors.
 */

.welcome-row,
.page-toolbar,
.page-header,
.dashboard-welcome {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 20px;
  min-width: 0;
}

.welcome-row > *,
.page-toolbar > *,
.page-header > *,
.dashboard-welcome > * {
  min-width: 0;
}

.welcome-row h2,
.page-toolbar h2,
.page-header h2,
.dashboard-welcome h2 {
  margin: 0 0 4px;
  color: var(--text-strong);
  font-size: 24px;
  letter-spacing: -.025em;
}

.welcome-row p,
.page-toolbar p,
.page-header p,
.dashboard-welcome p {
  margin: 0;
  color: var(--muted);
}

.eyebrow,
.card-eyebrow,
.page-eyebrow {
  margin: 0 0 5px;
  color: var(--brand);
  text-transform: uppercase;
  letter-spacing: .1em;
  font-size: 11px;
  font-weight: 800;
}

.content-grid,
.dashboard-grid,
.tailadmin-grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr);
  gap: 18px;
  min-width: 0;
}

.content-grid > *,
.dashboard-grid > *,
.tailadmin-grid > *,
.detail-grid > * {
  min-width: 0;
  max-width: 100%;
}

.span-2 {
  grid-column: span 2;
}

.detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.definition-list,
.detail-list {
  display: grid;
  gap: 0;
  margin: 0;
}

.definition-list > div,
.detail-list > div {
  display: grid;
  grid-template-columns: minmax(130px, .7fr) minmax(0, 1.3fr);
  gap: 12px;
  padding: 11px 0;
  border-bottom: 1px solid var(--border);
}

.definition-list > div:last-child,
.detail-list > div:last-child {
  border-bottom: 0;
}

.definition-list dt,
.detail-list dt {
  color: var(--muted);
}

.definition-list dd,
.detail-list dd {
  min-width: 0;
  margin: 0;
  color: var(--text-strong);
  font-weight: 600;
  overflow-wrap: anywhere;
}

.message-body {
  margin: 1rem 0;
  padding: 1rem;
  border-radius: 10px;
  background: var(--surface-2);
  overflow-wrap: anywhere;
}

.empty-state {
  padding: 38px 20px;
  display: grid;
  place-items: center;
  gap: 6px;
  color: var(--muted);
  text-align: center;
}

.empty-state.compact {
  padding: 25px 16px;
}

.empty-state strong,
.empty-state h3 {
  margin: 0;
  color: var(--text-strong);
}

.empty-state p {
  margin: 0;
}

.empty-icon {
  width: 43px;
  height: 43px;
  display: grid;
  place-items: center;
  border-radius: 11px;
  background: var(--brand-soft);
  color: var(--brand);
}

.content-narrow {
  width: min(760px, 100%);
}

.section-gap {
  margin-top: 18px;
}

.section-gap-bottom {
  margin-bottom: 18px;
}

.actions-end {
  justify-content: flex-end;
}

.card-actions-padded {
  padding: 18px;
}

@media (max-width: 900px) {
  .content-grid,
  .dashboard-grid,
  .tailadmin-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .span-2 {
    grid-column: auto;
  }
}

@media (max-width: 760px) {
  .welcome-row,
  .page-toolbar,
  .page-header,
  .dashboard-welcome {
    align-items: stretch;
    flex-direction: column;
    gap: 12px;
  }
  .page-toolbar > .button,
  .page-toolbar > .small-button,
  .page-header > .button,
  .welcome-row > .button,
  .dashboard-welcome > .button {
    width: 100%;
    justify-content: center;
  }
  .detail-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 520px) {
  .definition-list > div,
  .detail-list > div {
    grid-template-columns: minmax(0, 1fr);
    gap: 4px;
  }
}

/* Generic composition utilities shared by multiple page domains. */
.section-kicker {
  display: block;
  color: var(--brand);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.span-full {
  grid-column: 1 / -1;
}

.full-width {
  width: 100%;
}

.breakable {
  overflow-wrap: anywhere;
  word-break: break-word;
}

.muted {
  color: var(--muted);
}

.text-warning {
  color: var(--warning);
}

.text-danger {
  color: var(--danger);
}

.text-success {
  color: var(--success);
}


.relationship-list {
  display: grid;
  min-width: 0;
}
/* ===== END components/layout.css ===== */

/* ===== BEGIN components/buttons.css ===== */
/*
 * ARBS stylesheet: components/buttons.css
 * Purpose: Reusable button variants and action groups.
 * Architecture: Button appearance and action-group behaviour only.
 */

.button-row,
.filter-row,
.form-actions,
.emergency-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 9px;
  min-width: 0;
  max-width: 100%;
}

.button,
.button-secondary,
.link-button,
.small-button,
.danger-button {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 9px 15px;
  border: 1px solid var(--button-primary);
  border-radius: 9px;
  background: var(--button-primary);
  color: #fff;
  text-decoration: none;
  font-weight: 700;
  font-size: 14px;
  line-height: 1.2;
  text-align: center;
  white-space: normal;
  overflow-wrap: normal;
  word-break: normal;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
}

.button:hover,
.link-button:hover,
.small-button:hover {
  border-color: var(--button-primary-hover);
  background: var(--button-primary-hover);
  color: #fff;
  text-decoration: none;
}

.button:focus-visible,
.button-secondary:focus-visible,
.link-button:focus-visible,
.small-button:focus-visible,
.danger-button:focus-visible {
  outline: 3px solid var(--button-primary-focus);
  outline-offset: 2px;
}

.button.secondary,
.button-secondary,
.small-button.secondary {
  border-color: var(--border);
  background: var(--surface);
  color: var(--text);
}

.button.secondary:hover,
.button-secondary:hover,
.small-button.secondary:hover {
  border-color: var(--brand);
  background: var(--brand-softer);
  color: var(--brand-deep);
}

.button.small,
.small-button {
  min-height: 36px;
  padding: 7px 11px;
  font-size: 13px;
}

.button.full {
  width: 100%;
}

.danger-button,
.button.danger {
  border-color: var(--danger-strong);
  background: var(--danger-strong);
  color: #fff;
}

.danger-button:hover,
.button.danger:hover {
  border-color: var(--danger-hover);
  background: var(--danger-hover);
  color: #fff;
}

.button:disabled,
button:disabled,
.button.disabled {
  opacity: .55;
  cursor: not-allowed;
}

.form-actions {
  justify-content: flex-end;
  margin-top: 21px;
  padding-top: 18px;
  border-top: 1px solid var(--border);
}

@media (max-width: 760px) {
  .form-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .form-actions > .button,
  .form-actions > .button-secondary {
    width: 100%;
  }

  .button-row > .button,
  .button-row > .button-secondary,
  .button-row > .small-button {
    flex: 1 1 auto;
    min-width: min(100%, 140px);
  }
}

@media (max-width: 480px) {
  .button-row {
    align-items: stretch;
    flex-direction: column;
  }

  .button-row > .button,
  .button-row > .button-secondary,
  .button-row > .small-button,
  .button-row > form,
  .button-row > form > .button {
    width: 100%;
  }
}

.ghost-button {
  background: transparent;
}
/* ===== END components/buttons.css ===== */

/* ===== BEGIN components/alerts.css ===== */
/*
 * ARBS stylesheet: components/alerts.css
 * Purpose: Reusable notices, flash messages and status banners.
 * Architecture: Shared component layer; variants should use design tokens.
 */

.message-stack {
   display: grid;
   gap: 9px;
   margin-bottom: 16px;

}
 .flash-message, .alert, .notice, .registration-notice, .directory-notice, .emergency-notice, .humour-disclaimer, .payment-banner {
   padding: 13px 15px;
   border: 1px solid var(--border);
   border-radius: 10px;
   background: var(--info-soft);
   color: var(--text);

}
 .flash-message.success {
   background: var(--success-soft);
   border-color: var(--success-border);
   color: var(--success);

}
 .flash-message.error, .alert {
   background: var(--danger-soft);
   border-color: var(--danger-border);
   color: var(--danger);

}
 .flash-message.warning {
   background: var(--warning-soft);
   border-color: var(--warning-border);
   color: var(--warning);

}
 .flash-message.info, .flash-message.debug, .notice, .registration-notice, .directory-notice, .humour-disclaimer {
   background: var(--info-soft);
   border-color: var(--info-border);
   color: var(--info);

}
 .payment-banner {
   display: flex;
   align-items: center;
   justify-content: space-between;
   gap: 15px;
   margin-bottom: 18px;
   background: var(--warning-soft);
   border-color: var(--warning-border);

}
 .payment-banner.is-overdue {
   background: var(--danger-soft);
   border-color: var(--danger-border);
   color: var(--danger);

}

.danger-card {
  padding: 16px;
  border-color: var(--danger-border);
  background: var(--danger-soft);
}

.danger-card .inline-form {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.danger-card .inline-form .form-control {
  flex: 1 1 260px;
}

@media (max-width: 760px) {
  .danger-card .inline-form {
    align-items: stretch;
    flex-direction: column;
  }

  .danger-card .inline-form .form-control,
  .danger-card .inline-form .small-button {
    width: 100%;
  }
}
/* ===== END components/alerts.css ===== */

/* ===== BEGIN components/cards.css ===== */
/*
 * ARBS stylesheet: components/cards.css
 * Purpose: Reusable cards, panels, metrics, badges and content grids.
 * Architecture: Shared component layer; page composition belongs in pages/.
 */

 .panel, .card, .table-card, .form-card, .notice-card, .quick-card, .guidance-card, .history-card, .property-access-card, .rating-summary-card {
   border: 1px solid var(--border);
   border-radius: var(--radius);
   background: var(--surface);
   box-shadow: var(--shadow-sm);

}
 .card {
   overflow: hidden;

}
.narrow-card {
  width: min(760px, 100%);
}

/*
 * Card interior contract. Generic cards intentionally do not carry outer padding
 * because table and list cards are designed to run edge-to-edge. Content cards
 * therefore pad their body region, while table-wrap/model-form/stack-form and
 * specialised page components keep owning their established spacing.
 */
.card-body {
  min-width: 0;
  padding: 18px 20px 20px;
}

.card-body > :first-child {
  margin-top: 0;
}

.card-body > :last-child {
  margin-bottom: 0;
}

/* Definition/detail lists are content bodies rather than edge-to-edge tables. */
.card:not(.property-account-summary) > .definition-list,
.card > .detail-list {
  padding: 14px 20px 20px;
}

/* Action-only card bodies need the same inset as other card content. */
.card > .filter-row {
  padding: 18px 20px;
}

 .card-header, .panel-heading {
   display: flex;
   align-items: center;
   justify-content: space-between;
   gap: 14px;
   padding: 18px 20px;
   border-bottom: 1px solid var(--border);

}
 .card-header h3, .panel-heading h3 {
   margin: 0;
   color: var(--text-strong);
   font-size: 17px;

}
 .card-header p, .panel-heading p {
   margin: 3px 0 0;
   color: var(--muted);
   font-size: 13px;

}
 .card-link, .text-link, .table-link {
   color: var(--brand);
   font-weight: 700;
   text-decoration: none;

}
 .card-link:hover, .text-link:hover, .table-link:hover {
   text-decoration: underline;

}
 .metric-grid {
   display: grid;
   grid-template-columns: repeat(4, minmax(0,1fr));
   gap: 16px;
   margin-bottom: 18px;

}
 .metric-card {
   min-width: 0;
   display: flex;
   align-items: flex-start;
   gap: 13px;
   position: relative;
   padding: 18px;
   border: 1px solid var(--border);
   border-radius: var(--radius);
   background: var(--surface);
   box-shadow: var(--shadow-sm);

}
 a.metric-card {
   color: inherit;
   text-decoration: none;
   cursor: pointer;
   transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease, background-color .16s ease;

}
 a.metric-card:hover {
   color: inherit;
   text-decoration: none;
   transform: translateY(-2px);
   border-color: var(--brand);
   box-shadow: var(--shadow-md);

}
 a.metric-card:focus-visible {
   color: inherit;
   text-decoration: none;
   outline: 3px solid var(--brand-soft);
   outline-offset: 3px;
   border-color: var(--brand);

}
 .metric-card-chevron {
   position: absolute;
   top: 50%;
   right: 16px;
   transform: translateY(-50%);
   color: var(--muted-2);
   font-size: 20px;
   line-height: 1;

}
 a.metric-card:hover .metric-card-chevron, a.metric-card:focus-visible .metric-card-chevron {
   color: var(--brand);

}
 .metric-icon {
   flex: none;
   width: 44px;
   height: 44px;
   display: grid;
   place-items: center;
   border-radius: 11px;
   background: var(--brand-soft);
   color: var(--brand);
   font-weight: 800;

}
 .metric-copy {
   min-width: 0;

}
 .metric-card p {
   margin: 0 0 5px;
   color: var(--muted);
   font-size: 13px;

}
 .metric-card strong {
   display: block;
   color: var(--text-strong);
   font-size: 24px;
   line-height: 1.15;
   letter-spacing: -.025em;

}
 .metric-card small {
   display: block;
   margin-top: 5px;
   color: var(--muted-2);
   font-size: 11px;

}
 .metric-card-action {
   display: inline-flex;
   align-items: center;
   margin-top: 9px;
   color: var(--brand);
   font-size: 12px;
   font-weight: 800;
   text-decoration: none;

}
 a.metric-card:hover .metric-card-action, a.metric-card:focus-visible .metric-card-action {
   text-decoration: none;
   color: var(--brand-hover);

}
 .metric-trend {
   position: absolute;
   top: 15px;
   right: 15px;
   padding: 4px 7px;
   border-radius: 999px;
   font-size: 10px;
   font-weight: 800;

}
 .metric-trend.positive {
   color: var(--success);
   background: var(--success-soft);

}
 .metric-trend.warning {
   color: var(--warning);
   background: var(--warning-soft);

}
 .metric-trend.neutral {
   color: var(--info);
   background: var(--info-soft);

}
 .segmented {
   display: inline-flex;
   align-items: center;
   flex-wrap: wrap;
   gap: 8px;
   padding: 5px;
   border: 1px solid var(--border);
   border-radius: 10px;
   background: var(--surface);

}
 .segmented a {
   display: inline-flex;
   align-items: center;
   min-height: 38px;
   padding: 8px 13px;
   border-radius: 7px;
   color: var(--muted);
   font-weight: 700;
   text-decoration: none;
   white-space: nowrap;

}
 .segmented a:hover {
   background: var(--surface-2);
   color: var(--text-strong);

}
 .segmented a.active {
   background: var(--brand);
   color: #fff;

}
 .quick-actions {
   display: grid;
   padding: 7px 14px 14px;

}
 .quick-actions a {
   display: grid;
   grid-template-columns: 38px 1fr auto;
   align-items: center;
   gap: 11px;
   padding: 12px 7px;
   border-bottom: 1px solid var(--border);
   text-decoration: none;

}
 .quick-actions a:last-child {
   border-bottom: 0;

}
 .quick-actions a:hover {
   background: var(--surface-2);

}
 .quick-actions a > span {
   width: 36px;
   height: 36px;
   display: grid;
   place-items: center;
   border-radius: 9px;
   background: var(--brand-soft);
   color: var(--brand);

}
 .quick-actions strong, .quick-actions small {
   display: block;

}
 .quick-actions small {
   margin-top: 2px;
   color: var(--muted);
   font-size: 11px;

}
 .account-summary, .recon-summary {
   display: grid;
   grid-template-columns: repeat(3,minmax(0,1fr));
   margin-bottom: 18px;
   border: 1px solid var(--border);
   border-radius: var(--radius);
   background: var(--surface);

}
 .account-summary > div, .recon-summary > div {
   padding: 16px 18px;
   border-right: 1px solid var(--border);

}
 .account-summary > div:last-child, .recon-summary > div:last-child {
   border-right: 0;

}
 .account-summary span, .recon-summary span {
   display: block;
   color: var(--muted);
   font-size: 12px;

}
 .account-summary strong, .recon-summary strong {
   display: block;
   margin-top: 3px;
   color: var(--text-strong);
   font-size: 22px;

}
 .report-grid {
   display: grid;
   grid-template-columns: repeat(3,minmax(0,1fr));
   gap: 16px;

}
 .report-card {
   min-width: 0;
   display: flex;
   gap: 13px;
   padding: 19px;
   border: 1px solid var(--border);
   border-radius: var(--radius);
   background: var(--surface);
   text-decoration: none;
   box-shadow: var(--shadow-sm);

}
 .report-card:hover {
   border-color: var(--brand);
   box-shadow: var(--shadow-md);
   transform: translateY(-1px);

}
 .report-card > span {
   flex: none;
   width: 42px;
   height: 42px;
   display: grid;
   place-items: center;
   border-radius: 11px;
   background: var(--brand-soft);
   color: var(--brand);

}
 .report-card h3 {
   margin: 0 0 5px;
   color: var(--text-strong);

}
 .report-card p {
   margin: 0;
   color: var(--muted);
   font-size: 13px;

}
 .progress-block {
   padding: 20px;

}
 .progress-label {
   display: flex;
   justify-content: space-between;
   gap: 10px;

}
 .progress {
   height: 8px;
   margin: 11px 0;
   overflow: hidden;
   border-radius: 999px;
   background: var(--surface-3);

}
 .progress span {
   display: block;
   height: 100%;
   background: var(--brand);

}
/* Shared card collections used across more than one page family. */
.property-card-grid,
.report-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  min-width: 0;
}

.metric-grid > *,
.property-card-grid > *,
.report-grid > * {
  min-width: 0;
  max-width: 100%;
}

@media (max-width: 1100px) {
  .metric-grid,
  .property-card-grid,
  .report-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .metric-grid,
  .property-card-grid,
  .report-grid,
  .account-summary,
  .recon-summary {
    grid-template-columns: minmax(0, 1fr);
  }
  .account-summary > div,
  .recon-summary > div {
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }
  .account-summary > div:last-child,
  .recon-summary > div:last-child {
    border-bottom: 0;
  }
}

.sticky-card {
  position: sticky;
  top: calc(var(--topbar-height) + 20px);
}

.guidance-stack {
  display: grid;
  gap: 0;
}

.guidance-stack > div {
  padding: 15px 0;
  border-bottom: 1px solid var(--border);
}

.guidance-stack > div:first-child {
  padding-top: 0;
}

.guidance-stack > div:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.guidance-stack strong {
  color: var(--text-strong);
}

.guidance-stack p {
  margin: 5px 0 0;
  color: var(--muted);
  line-height: 1.5;
}

@media (max-width: 1100px) {
  .sticky-card {
    position: static;
  }
}
/* ===== END components/cards.css ===== */

/* ===== BEGIN components/forms.css ===== */
/*
 * ARBS stylesheet: components/forms.css
 * Purpose: Reusable controls, generic form/filter grids and native temporal inputs.
 * Architecture: Shared form primitives only. Domain-specific field arrangements belong in pages/.
 */

.model-form,
.stack-form {
  padding: 20px;
}

.form-layout {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr);
  gap: 18px;
  align-items: start;
  min-width: 0;
}

.form-layout > * {
  min-width: 0;
}

.form-grid {
  display: grid;
  gap: 17px;
  min-width: 0;
}

.form-grid.two-column {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.form-grid.compact-form-grid {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
  align-items: start;
}

.form-grid > *,
.form-grid.compact-form-grid > * {
  min-width: 0;
}

.field-group,
.form-group,
.filter-grid label {
  min-width: 0;
  display: grid;
  gap: 7px;
  color: var(--text);
  font-size: 13px;
  font-weight: 700;
}

.field-group > label,
.form-group > label,
.filter-grid label > span {
  display: block;
  min-width: 0;
  min-height: 0;
  margin: 0;
  line-height: 1.4;
  white-space: normal;
  overflow-wrap: break-word;
}

.form-grid.two-column {
  align-items: start;
}

.required {
  color: var(--danger);
}

input:not([type="checkbox"]):not([type="radio"]),
select,
textarea,
.form-control {
  display: block;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  min-height: 46px;
  padding: 10px 13px;
  border: 1px solid var(--border-strong);
  border-radius: 9px;
  outline: none;
  background: var(--surface);
  color: var(--text);
  box-shadow: inset 0 1px 1px rgba(16, 38, 31, .025);
}

textarea {
  min-height: 116px;
  resize: vertical;
}

input::placeholder,
textarea::placeholder {
  color: var(--muted-2);
  opacity: 1;
}

input:focus,
select:focus,
textarea:focus,
.form-control:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 15%, transparent);
}

input:disabled,
select:disabled,
textarea:disabled {
  background: var(--surface-3);
  color: var(--muted);
  opacity: 1;
}

input[type="checkbox"],
input[type="radio"] {
  width: 18px;
  height: 18px;
  accent-color: var(--brand);
}

.help-text {
  color: var(--muted);
  font-size: 12px;
  font-weight: 400;
  line-height: 1.45;
}

.field-error,
.error-text {
  color: var(--danger);
  font-size: 12px;
  font-weight: 600;
}

.form-section-title {
  margin: 22px 0 12px;
  color: var(--text-strong);
  font-size: 16px;
}

.guidance-list {
  padding: 14px 20px;
}

.guidance-list > div {
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
}

.guidance-list > div:last-child {
  border-bottom: 0;
}

.guidance-list strong {
  color: var(--text-strong);
}

.guidance-list p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
}

/* All filter forms opt into one shared layout with class="filter-grid". */
.filter-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 180px), 1fr));
  align-items: end;
  gap: 12px;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  margin: 0 0 18px;
  padding: 15px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}

.filter-grid > * {
  min-width: 0;
  max-width: 100%;
}

.filter-grid > button[type="submit"],
.filter-grid > .report-filter-action {
  align-self: end;
  width: auto;
  min-width: 112px;
  min-height: 46px;
  margin: 0;
}

.search-box {
  width: 100%;
  min-width: 0;
  max-width: 100%;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 11px;
  border: 1px solid var(--border-strong);
  border-radius: 9px;
  background: var(--surface);
}

.search-box > input:not([type="checkbox"]):not([type="radio"]) {
  min-height: 44px;
  padding-inline: 0;
  border: 0;
  box-shadow: none;
}

/* Native date/time controls use a wrapper because iOS may size browser chrome
 * wider than a grid track when border and padding are applied to the input. */
.native-temporal-control {
  display: flex;
  align-items: center;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  min-height: 46px;
  padding: 10px 13px;
  border: 1px solid var(--border-strong);
  border-radius: 9px;
  background: var(--surface);
  color: var(--text);
  box-shadow: inset 0 1px 1px rgba(16, 38, 31, .025);
}

.native-temporal-control:focus-within {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 15%, transparent);
}

.native-temporal-control > input[type="date"],
.native-temporal-control > input[type="datetime-local"],
.native-temporal-control > input[type="time"],
.native-temporal-control > input[type="month"],
.native-temporal-control > input[type="week"] {
  display: block;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  min-height: 24px;
  height: auto;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  outline: 0;
  background: transparent;
  color: inherit;
  box-shadow: none;
  font: inherit;
}

.native-temporal-control > input:focus {
  border: 0;
  box-shadow: none;
}

input[type="date"],
input[type="datetime-local"],
input[type="time"],
input[type="month"],
input[type="week"] {
  min-width: 0;
  max-width: 100%;
}

.sticky-form-actions {
  position: sticky;
  bottom: 0;
  z-index: 8;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 10px;
  width: 100%;
  margin-top: 20px;
  padding: 14px 18px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: color-mix(in srgb, var(--surface) 94%, transparent);
  box-shadow: 0 -8px 26px rgba(16, 38, 31, .08);
  backdrop-filter: blur(12px);
}

.inline-form {
  display: inline;
}

@media (max-width: 900px) {
  .form-layout {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 760px) {
  .form-grid,
  .form-grid.two-column,
  .form-grid.compact-form-grid,
  .filter-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .form-grid > *,
  .filter-grid > * {
    grid-column: auto;
    width: 100%;
    min-width: 0;
    max-width: 100%;
  }

  .filter-grid > button[type="submit"],
  .filter-grid > .report-filter-action,
  .filter-grid > .filter-actions,
  .filter-grid > [class$="-filter-actions"] {
    width: 100%;
    justify-content: center;
  }

  .filter-grid > .filter-actions .button,
  .filter-grid > [class$="-filter-actions"] .button {
    flex: 1 1 100%;
  }

  .model-form,
  .stack-form {
    padding: 16px;
  }

  .sticky-form-actions {
    align-items: stretch;
    flex-direction: column-reverse;
  }

  .sticky-form-actions .button {
    width: 100%;
  }
}
/* ===== END components/forms.css ===== */

/* ===== BEGIN components/dropdowns.css ===== */
/*
 * ARBS stylesheet: components/dropdowns.css
 * Purpose: Reusable details/summary dropdown menus.
 * Architecture: Shared dropdown selectors only.
 */

.export-dropdown {
   position:relative;
   display:inline-block
}
 .export-dropdown>summary {
   list-style:none;
   cursor:pointer
}
 .export-dropdown>summary::-webkit-details-marker {
   display:none
}
 .export-dropdown>summary::after {
   content:" ▾"
}
 .export-dropdown[open]>summary::after {
   content:" ▴"
}
 .export-dropdown-menu {
   position:absolute;
   right:0;
   top:calc(100% + 6px);
   z-index:50;
   min-width:150px;
   padding:6px;
   border:1px solid var(--border);
   border-radius:10px;
   background:var(--surface);
   box-shadow:var(--shadow-lg)
}
 .export-dropdown-menu a {
   display:block;
   padding:9px 10px;
   border-radius:7px;
   color:var(--text);
   text-decoration:none;
   white-space:nowrap
}
 .export-dropdown-menu a:hover {
   background:var(--surface-2)
}
/* ===== END components/dropdowns.css ===== */

/* ===== BEGIN components/tables.css ===== */
/*
 * ARBS stylesheet: components/tables.css
 * Purpose: Semantic table presentation and bounded horizontal overflow.
 * Architecture: Generic table primitives only; domain column sizing belongs in page modules.
 */

.table-wrap {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow-x: auto;
  overflow-y: hidden;
  overscroll-behavior-inline: contain;
  -webkit-overflow-scrolling: touch;
  scrollbar-gutter: stable;
}

.table-wrap table,
table {
  width: 100%;
  border-collapse: collapse;
  color: var(--text);
  font-size: 13px;
}

/* Runtime data tables must remain readable.  A bounded wrapper owns horizontal
 * scrolling; the table itself must not shrink columns until labels and values
 * become unreadable.  PDF tables do not use .table-wrap and are unaffected. */
.table-wrap > table {
  min-width: 760px;
  table-layout: auto;
}

.table-wrap > table.dense-table {
  min-width: 1100px;
}

.table-wrap > table.very-wide-table {
  min-width: 1500px;
}

th {
  padding: 12px 15px;
  border-bottom: 1px solid var(--border);
  background: var(--surface-2);
  color: var(--muted);
  text-align: left;
  text-transform: uppercase;
  letter-spacing: .055em;
  font-size: 10px;
  font-weight: 800;
  white-space: nowrap;
}

td {
  min-width: 0;
  padding: 14px 15px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
  overflow-wrap: normal;
  word-break: normal;
}

tbody tr:hover {
  background: var(--brand-softer);
}

tbody tr:last-child td {
  border-bottom: 0;
}

td.numeric,
th.numeric,
td.number,
th.number {
  text-align: right;
  white-space: nowrap;
}

.table-subtext {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
}

.badge,
.status-badge,
.count-pill,
.channel-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  max-width: 100%;
  padding: 5px 9px;
  border-radius: 999px;
  background: var(--surface-3);
  color: var(--muted);
  font-size: 11px;
  line-height: 1;
  font-weight: 800;
  white-space: nowrap;
}

.badge.active,
.badge.paid,
.badge.posted,
.badge.allocated,
.badge.matched,
.status-badge.active,
.status-badge.paid {
  background: var(--success-soft);
  color: var(--success);
}

.badge.draft,
.badge.imported,
.badge.part_paid,
.badge.part_allocated,
.status-badge.warning {
  background: var(--warning-soft);
  color: var(--warning);
}

.badge.void,
.badge.reversed,
.badge.suspended,
.status-badge.danger {
  background: var(--danger-soft);
  color: var(--danger);
}

@media (max-width: 760px) {
  th,
  td {
    padding-inline: 12px;
  }
}
/* ===== END components/tables.css ===== */

/* ===== BEGIN components/pagination.css ===== */
/*
 * ARBS stylesheet: components/pagination.css
 * Purpose: Canonical ARBS pagination component.
 * Architecture: Pagination selectors only.
 */

.pagination,
.pagination-bar,
.pagination-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  max-width: 100%;
  margin: 20px 0 4px;
  padding: 16px 18px;
}

.pagination > a,
.pagination > span {
  text-decoration: none;
}

.pagination .active {
  background: var(--button-primary);
  border-color: var(--button-primary);
  color: #fff;
}

.pagination .pagination-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-width: 132px;
  min-height: 44px;
  padding: 9px 16px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface-2);
  color: var(--text-strong);
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
}

.pagination .pagination-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 104px;
  min-height: 44px;
  padding: 10px 18px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 750;
  line-height: 1;
  white-space: nowrap;
  transition: background-color .16s ease, border-color .16s ease, color .16s ease, box-shadow .16s ease;
}

.pagination .pagination-previous {
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-strong);
}

.pagination .pagination-previous:hover {
  border-color: var(--button-primary);
  color: var(--brand-deep);
  background: var(--brand-soft);
}

.pagination .pagination-next {
  min-width: 112px;
  border: 1px solid var(--button-primary);
  background: var(--button-primary);
  color: #fff;
  box-shadow: var(--shadow-sm);
}

.pagination .pagination-next:hover {
  border-color: var(--button-primary-hover);
  background: var(--button-primary-hover);
  color: #fff;
}

.pagination .pagination-button:focus-visible {
  outline: 3px solid var(--button-primary-focus);
  outline-offset: 2px;
}

.pagination .pagination-button.is-disabled {
  opacity: .42;
  cursor: not-allowed;
  pointer-events: none;
  box-shadow: none;
}

@media (max-width: 560px) {
  .pagination {
    padding-inline: 10px;
  }
  .pagination .pagination-status {
    order: -1;
    flex: 1 0 100%;
  }
  .pagination .pagination-button {
    flex: 1 1 calc(50% - 5px);
    min-width: 0;
  }
}
/* ===== END components/pagination.css ===== */

/* ===== BEGIN components/staff.css ===== */
/*
 * ARBS stylesheet: components/staff.css
 * Purpose: Reusable staff-workflow headers, cards, filters, details and action layouts.
 * Architecture: Shared component layer used by billing, reconciliation, users, parties,
 * contractors, invoices and analytics. Domain-specific content remains in pages/.
 */

.staff-page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1.5rem;
  margin-bottom: 1.25rem;
  min-width: 0;
}

.staff-page-header > * {
  min-width: 0;
}

.staff-page-header h2 {
  margin: .2rem 0 .35rem;
}

.staff-page-header p {
  margin: 0;
  color: var(--muted);
}

.staff-action-row {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 9px;
  min-width: 0;
  max-width: 100%;
}

.staff-action-row form {
  margin: 0;
}

.staff-card,
.staff-filter-card,
.staff-guidance-card {
  min-width: 0;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.staff-filter-card {
  overflow: hidden;
}

.staff-card-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem 1.4rem;
  border-bottom: 1px solid var(--border);
}

.staff-card-heading > * {
  min-width: 0;
}

.staff-card-heading h3 {
  margin: .15rem 0 .25rem;
}

.staff-card-heading p {
  margin: 0;
  color: var(--muted);
}

.staff-card-body {
  padding: 1.35rem 1.4rem;
}

.staff-eyebrow {
  display: block;
  color: var(--brand);
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .09em;
  text-transform: uppercase;
}

.staff-section-gap {
  margin-top: 1.25rem;
}

/* Filter-grid owns the field behaviour. The staff card only supplies composition. */
.staff-filter-card > .filter-grid,
.staff-filter-grid {
  margin: 0;
  padding: 1.25rem 1.4rem;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.staff-filter-grid {
  grid-template-columns: minmax(240px, 2fr) repeat(auto-fit, minmax(160px, 1fr));
}

.staff-filter-search {
  min-width: 0;
}

.staff-filter-actions {
  display: flex;
  align-items: center;
  align-self: end;
  flex-wrap: wrap;
  gap: .65rem;
  min-width: 0;
  min-height: 46px;
}

.staff-filter-actions .button {
  min-height: 46px;
  white-space: nowrap;
}

.staff-guidance-card {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.staff-guidance-card > div {
  min-width: 0;
  padding: 1.25rem 1.4rem;
}

.staff-guidance-card > div + div {
  border-left: 1px solid var(--border);
}

.staff-guidance-card strong {
  display: block;
  margin-bottom: .35rem;
}

.staff-guidance-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.staff-two-column {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr);
  gap: 1.25rem;
}

.staff-stack,
.staff-form-shell,
.staff-list-stack {
  display: grid;
  gap: 1.25rem;
  min-width: 0;
  align-content: start;
}

.staff-list-stack {
  gap: .75rem;
}

.staff-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem 1.5rem;
  margin: 0;
}

.staff-detail-grid > div {
  min-width: 0;
}

.staff-detail-grid dt {
  color: var(--muted);
  font-size: .76rem;
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.staff-detail-grid dd {
  margin: .3rem 0 0;
  font-weight: 650;
  overflow-wrap: anywhere;
}

.identity-summary {
  display: grid;
  gap: .45rem;
}

.identity-summary .button {
  justify-self: start;
  margin-top: .5rem;
}

.staff-list-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: .9rem 0;
  border-bottom: 1px solid var(--border);
}

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

.staff-list-row span {
  display: block;
  margin-top: .2rem;
  color: var(--muted);
  font-size: .85rem;
}

.staff-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.1rem 1.25rem;
}

.staff-form-grid > *,
.staff-form-grid .field-group {
  min-width: 0;
}

.staff-form-actions {
  display: flex;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: .75rem;
  padding: 1rem 0;
}

.plot-chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: .4rem;
}

@media (max-width: 1100px) {
  .staff-filter-search,
  .staff-filter-actions {
    grid-column: 1 / -1;
  }

  .staff-two-column {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 760px) {
  .staff-page-header {
    align-items: stretch;
    flex-direction: column;
    gap: 1rem;
  }

  .staff-action-row {
    align-items: stretch;
    flex-direction: column;
    width: 100%;
  }

  .staff-action-row > .button,
  .staff-action-row > .button-secondary,
  .staff-action-row > form,
  .staff-action-row > form > .button {
    width: 100%;
  }

  .staff-filter-grid,
  .staff-guidance-card,
  .staff-detail-grid,
  .staff-form-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .staff-filter-search,
  .staff-filter-actions {
    grid-column: auto;
  }

  .staff-filter-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .staff-filter-actions .button {
    width: 100%;
  }

  .staff-guidance-card > div + div {
    border-top: 1px solid var(--border);
    border-left: 0;
  }

  .staff-card-heading {
    align-items: stretch;
    flex-direction: column;
  }

  .staff-card-heading > .button,
  .staff-card-heading > form,
  .staff-card-heading > form > .button {
    width: 100%;
  }

  .staff-list-row {
    align-items: flex-start;
  }

  .staff-form-actions {
    position: sticky;
    bottom: 0;
    z-index: 5;
    align-items: stretch;
    flex-direction: column-reverse;
    padding: 1rem;
    background: var(--canvas);
  }

  .staff-form-actions .button {
    width: 100%;
  }
}
/* ===== END components/staff.css ===== */

/* ===== BEGIN pages/public.css ===== */
/*
 * ARBS stylesheet: pages/public.css
 * Purpose: Public ARBS landing page.
 * Architecture: Public-home selectors only.
 */

.public-home-body {
   min-height: 100vh;
   background: #eef4f1;

}
 .public-home-shell {
   min-height: 100vh;
   display: grid;
   grid-template-columns: minmax(0,1.18fr) minmax(420px,.82fr);

}
 .public-home-hero {
   position: relative;
   overflow: hidden;
   display: flex;
   flex-direction: column;
   padding: clamp(34px,5vw,72px);
   background: linear-gradient(145deg, #123e34 0%, #1a6657 58%, #0d8775 100%);
   color: #fff;

}
 .public-home-glow {
   position: absolute;
   border-radius: 50%;
   background: rgba(110,231,215,.11);
   filter: blur(2px);

}
 .public-home-glow-one {
   width: 430px;
   height: 430px;
   top: -180px;
   right: -150px;

}
 .public-home-glow-two {
   width: 300px;
   height: 300px;
   bottom: -140px;
   left: -90px;

}
 .public-home-brand {
   position: relative;
   z-index: 1;
   display: flex;
   align-items: center;
   gap: 12px;

}
 .public-home-brand strong, .public-home-brand small {
   display: block;

}
 .public-home-brand strong {
   font-size: 19px;

}
 .public-home-brand small {
   color: #b7d7ce;
   font-style: italic;

}
 .public-home-copy {
   position: relative;
   z-index: 1;
   max-width: 760px;
   margin: auto 0;
   padding: 60px 0;

}
 .public-home-kicker {
   margin: 0 0 14px;
   color: #a9e5db;
   text-transform: uppercase;
   letter-spacing: .13em;
   font-size: 12px;
   font-weight: 800;

}
 .public-home-copy h1 {
   max-width: 720px;
   margin: 0;
   font-size: clamp(42px,5.3vw,74px);
   line-height: 1.02;
   letter-spacing: -.052em;

}
 .public-home-lead {
   max-width: 650px;
   margin: 25px 0 0;
   color: #d2e9e3;
   font-size: 18px;
   line-height: 1.65;

}
 .public-home-actions {
   display: flex;
   flex-wrap: wrap;
   gap: 10px;
   margin-top: 30px;

}
 .public-primary-button, .public-secondary-button {
   min-height: 48px;
   display: inline-flex;
   align-items: center;
   justify-content: center;
   gap: 9px;
   padding: 11px 18px;
   border-radius: 10px;
   text-decoration: none;
   font-weight: 750;

}
 .public-primary-button {
   background: #fff;
   color: #135b4e;

}
 .public-primary-button:hover {
   background: #e9f7f3;

}
 .public-secondary-button {
   border: 1px solid rgba(255,255,255,.27);
   color: #fff;
   background: rgba(255,255,255,.07);

}
 .public-secondary-button:hover {
   background: rgba(255,255,255,.13);

}
 .public-home-features {
   display: grid;
   grid-template-columns: repeat(3,minmax(0,1fr));
   gap: 12px;
   margin-top: 42px;

}
 .public-home-features article {
   display: grid;
   grid-template-columns: 31px 1fr;
   gap: 9px;
   padding: 13px 0;
   border-top: 1px solid rgba(255,255,255,.17);

}
 .public-home-features article > span {
   color: #8ce0d3;
   font-size: 11px;
   font-weight: 800;

}
 .public-home-features strong, .public-home-features small {
   display: block;

}
 .public-home-features strong {
   font-size: 13px;

}
 .public-home-features small {
   margin-top: 3px;
   color: #b9d5cd;
   font-size: 11px;

}
 .public-home-footer {
   position: relative;
   z-index: 1;
   color: #aacbc2;
   font-size: 12px;

}
 .public-home-login-panel {
   display: grid;
   place-items: center;
   padding: 38px;
   background: var(--surface);

}
 .public-home-login-card {
   width: min(440px,100%);

}
 .public-login-icon {
   width: 54px;
   height: 54px;
   display: grid;
   place-items: center;
   border-radius: 14px;
   background: var(--brand-soft);
   color: var(--brand);
   font-size: 13px;
   font-weight: 850;

}
 .public-home-login-card h2 {
   margin: 8px 0 4px;
   color: var(--text-strong);
   font-size: 32px;
   letter-spacing: -.035em;

}
 .public-home-login-card > p {
   color: var(--muted);

}
 .public-login-button {
   margin-top: 22px;

}
 .public-registration-notice {
   margin-top: 16px;
   background: var(--brand-softer);
   border-color: color-mix(in srgb, var(--brand) 20%, var(--border));

}
 .public-registration-notice p {
   margin: 5px 0 0;
   color: var(--muted);

}
 .public-security-note {
   display: grid;
   grid-template-columns: 29px 1fr;
   gap: 10px;
   align-items: center;
   margin-top: 18px;
   padding: 13px 0;
   border-top: 1px solid var(--border);
   border-bottom: 1px solid var(--border);

}
 .public-security-note > span {
   width: 27px;
   height: 27px;
   display: grid;
   place-items: center;
   border-radius: 50%;
   background: var(--success-soft);
   color: var(--success);
   font-weight: 800;

}
 .public-security-note p {
   margin: 0;

}
 .public-security-note strong, .public-security-note small {
   display: block;

}
 .public-security-note small {
   color: var(--muted);

}
 .public-admin-link {
   display: inline-block;
   margin-top: 17px;
   color: var(--brand);
   font-weight: 700;
   text-decoration: none;

}

@media (max-width: 900px) {
  .public-home-shell {
    grid-template-columns: minmax(0, 1fr);
  }
  .public-home-hero {
    min-height: 680px;
  }
  .public-home-login-panel {
    padding-block: 60px;
  }
}

@media (max-width: 760px) {
  .public-home-hero {
    min-height: 620px;
    padding: 28px 22px;
  }
  .public-home-copy {
    padding: 44px 0;
  }
  .public-home-copy h1 {
    font-size: 43px;
  }
  .public-home-features {
    grid-template-columns: minmax(0, 1fr);
  }
  .public-home-login-panel {
    padding: 28px 20px;
  }
}
/* ===== END pages/public.css ===== */

/* ===== BEGIN pages/auth.css ===== */
/*
 * ARBS stylesheet: pages/auth.css
 * Purpose: Login, invitation and password-reset pages.
 * Architecture: Authentication selectors only.
 */

.auth-body {
   min-height: 100vh;
   background: var(--canvas);

}
 .auth-shell, .tailadmin-auth {
   min-height: 100vh;
   display: grid;
   grid-template-columns: minmax(0,1.15fr) minmax(420px,.85fr);

}
 .auth-brand {
   position: relative;
   overflow: hidden;
   display: flex;
   flex-direction: column;
   justify-content: center;
   padding: clamp(48px,8vw,115px);
   background: linear-gradient(145deg, #123e34, #0f7868);
   color: #fff;

}
 .auth-brand-inner {
   position: relative;
   z-index: 1;
   max-width: 660px;

}
 .auth-community {
   margin: 22px 0 0;
   font-weight: 800;

}
 .auth-tagline {
   margin: 3px 0 30px;
   color: #a7e4d9;
   font-style: italic;

}
 .auth-brand h1 {
   max-width: 700px;
   margin: 0;
   font-size: clamp(42px,5vw,72px);
   line-height: 1.02;
   letter-spacing: -.05em;

}
 .auth-copy {
   max-width: 590px;
   color: #d1e8e2;
   font-size: 17px;
   line-height: 1.65;

}
 .auth-feature-grid {
   display: grid;
   grid-template-columns: repeat(2,minmax(0,1fr));
   gap: 12px 20px;
   margin-top: 30px;
   color: #d3eee8;
   font-size: 14px;

}
 .auth-orb {
   position: absolute;
   border-radius: 50%;
   background: rgba(94,234,212,.1);

}
 .auth-orb-one {
   width: 420px;
   height: 420px;
   right: -160px;
   top: -160px;

}
 .auth-orb-two {
   width: 270px;
   height: 270px;
   left: -90px;
   bottom: -90px;

}
 .auth-card-wrap {
   display: grid;
   place-items: center;
   padding: 38px;
   background: var(--surface);

}
 .auth-card {
   width: min(430px,100%);

}
 .auth-heading h2, .auth-card h2 {
   margin: 7px 0 4px;
   color: var(--text-strong);
   font-size: 29px;
   letter-spacing: -.035em;

}
 .auth-heading p, .auth-card p {
   color: var(--muted);

}
 .form-stack {
   display: grid;
   gap: 16px;
   margin-top: 22px;

}
 .form-stack label {
   display: grid;
   gap: 7px;
   color: var(--text);
   font-size: 13px;
   font-weight: 700;

}
 .login-options {
   display: flex;
   align-items: center;
   justify-content: space-between;
   gap: 12px;

}
 .auth-submit {
   min-height: 48px;

}
 .auth-footer {
   margin-top: 22px;
   color: var(--muted);
   text-align: center;
   font-size: 12px;

}
 .auth-link {
   color: var(--brand);
   font-weight: 700;

}

.auth-standalone-shell {
   min-height: 100vh;
   display: grid;
   place-items: center;
   padding: 48px 24px;
   background: var(--surface);

}
 .auth-mobile-brand {
   display: none;
   align-items: center;
   gap: 14px;
   margin-bottom: 28px;

}
 .auth-mobile-brand-copy {
   display: grid;
   gap: 3px;
   line-height: 1.2;

}
 .auth-mobile-brand-copy strong {
   color: var(--text-strong);
   font-size: 18px;

}
 .auth-mobile-brand-copy span {
   color: var(--brand);
   font-size: 14px;
   font-style: italic;

}
 .auth-card.standalone .auth-mobile-brand {
   display: flex;

}
@media (max-width: 900px) {
  .auth-shell,
  .tailadmin-auth {
    grid-template-columns: minmax(0, 1fr);
  }
  .auth-brand {
    display: none;
  }
  .auth-card-wrap {
    min-height: 100vh;
    padding: 42px 28px;
  }
  .auth-card:not(.standalone) .auth-mobile-brand {
    display: flex;
  }
}

@media (max-width: 760px) {
  .auth-card-wrap,
  .auth-standalone-shell {
    min-height: 100vh;
    align-items: start;
    padding: 34px 20px 42px;
  }
  .auth-card {
    width: 100%;
    max-width: 520px;
  }
  .auth-mobile-brand {
    margin-bottom: 32px;
  }
  .auth-heading h2,
  .auth-card h2 {
    font-size: 30px;
  }
}

@media (max-width: 380px) {
  .auth-card-wrap,
  .auth-standalone-shell {
    padding-inline: 16px;
  }
}
/* ===== END pages/auth.css ===== */

/* ===== BEGIN pages/humour.css ===== */
/*
 * ARBS stylesheet: pages/humour.css
 * Purpose: Daily Laugh season and episode pages.
 * Architecture: Humour selectors only.
 */

.daily-laugh-heading h2 {
   margin-bottom: 6px;
   font-size: 30px;
   line-height: 1.2;

}
 .daily-laugh-heading p {
   margin: 0;
   font-size: 17px;
   line-height: 1.35;

}
 .season-grid {
   display: grid;
   gap: 18px;

}
 .humour-season {
   overflow: hidden;

}
 .humour-season-header h3 {
   margin: 0;
   font-size: 21px;
   line-height: 1.2;

}
 .humour-season-header p {
   margin: 4px 0 0;
   font-size: 15px;
   line-height: 1.2;

}
 .episode-list {
   display: block;
   margin: 0;
   padding: 0;
   list-style: none;

}
 .episode-list-item {
   margin: 0;
   padding: 0;
   border-top: 1px solid var(--border);

}
 .episode-list-item:first-child {
   border-top: 0;

}
 .episode-row {
   min-width: 0;
   display: grid;
   grid-template-columns: 72px minmax(0, 1fr) 24px;
   align-items: center;
   column-gap: 14px;
   padding: 16px 20px;
   color: var(--text-strong);
   text-decoration: none;
   line-height: 1.2;

}
 .episode-row:hover, .episode-row:focus-visible {
   background: var(--brand-softer);

}
 .episode-code {
   color: var(--brand);
   font-size: 15px;
   line-height: 1.2;
   font-weight: 800;
   white-space: nowrap;

}
 .episode-title {
   min-width: 0;
   overflow: hidden;
   color: var(--text-strong);
   font-size: 18px;
   line-height: 1.2;
   font-weight: 650;
   white-space: nowrap;
   text-overflow: ellipsis;

}
 .episode-arrow {
   justify-self: end;
   color: var(--muted);
   font-size: 20px;
   line-height: 1;

}
 .episode-row:hover .episode-arrow, .episode-row:focus-visible .episode-arrow {
   color: var(--brand);
   transform: translateX(2px);

}
 .humour-article {
   overflow: hidden;

}
 .humour-article-body {
   padding: 22px;
   max-width: 820px;
   font-size: 18px;
   line-height: 1.45;

}

@media (max-width: 760px) {
  .episode-row {
    grid-template-columns: 64px minmax(0, 1fr) 20px;
    padding: 14px 16px;
    column-gap: 10px;
  }
  .episode-code {
    font-size: 14px;
  }
  .episode-title {
    font-size: 17px;
  }
}
/* ===== END pages/humour.css ===== */

/* ===== BEGIN pages/dashboard.css ===== */
/*
 * ARBS stylesheet: pages/dashboard.css
 * Purpose: Staff dashboard layout and quick-action composition.
 * Architecture: Page layer; loaded after shared components.
 */

.finance-metrics a.metric-card {
   padding-right: 88px;

}
 .finance-metrics a.metric-card .metric-trend {
   text-decoration: none;

}
 .finance-metrics a.metric-card:hover .metric-trend, .finance-metrics a.metric-card:focus-visible .metric-trend {
   text-decoration: none;

}
 /* Dashboard desktop space utilisation */
 .dashboard-data-stack {
   display:grid;
   gap:18px
}
 .dashboard-operations-grid {
   display:grid;
   grid-template-columns:minmax(0,2fr) minmax(300px,1fr);
   gap:18px;
   align-items:stretch;
   margin-top:18px
}
 .dashboard-operations-grid>.card {
   height:100%
}
 .dashboard-operations-grid .health-card,.dashboard-operations-grid .quick-card {
   display:flex;
   flex-direction:column
}
 .dashboard-operations-grid .progress-block,.dashboard-operations-grid .quick-actions {
   flex:1
}
 .dashboard-operations-grid .quick-actions a {
   min-height:57px;
   box-sizing:border-box
}
 .health-card .progress-block {
   display:grid;
   grid-template-columns:120px minmax(0,1fr);
   gap:20px;
   align-items:center
}
 .donut-placeholder {
   width:112px;
   aspect-ratio:1;
   display:grid;
   place-items:center;
   align-content:center;
   border-radius:50%;
   background:conic-gradient(var(--brand) 0deg, var(--surface-3) 0deg);
   box-shadow:inset 0 0 0 16px var(--surface)
}
 .donut-placeholder span {
   color:var(--text-strong);
   font-size:24px;
   font-weight:800;
   line-height:1
}
 .donut-placeholder small {
   margin-top:4px;
   color:var(--muted);
   font-size:10px;
   font-weight:700;
   text-transform:uppercase;
   letter-spacing:.06em
}
 .health-legend {
   display:grid;
   gap:10px;
   min-width:0
}
 .health-legend p {
   display:grid;
   grid-template-columns:10px minmax(0,1fr) auto;
   align-items:center;
   gap:9px;
   margin:0
}
 .health-legend strong {
   color:var(--text-strong);
   text-align:right;
   white-space:nowrap
}
 .legend-dot {
   width:9px;
   height:9px;
   border-radius:50%;
   background:var(--brand)
}
 .legend-dot.outstanding {
   background:var(--warning-strong)
}
 .health-note {
   grid-column:1 / -1;
   color:var(--muted);
   line-height:1.45
}

/* Dashboard phone layout. */
@media (max-width: 760px) {
  .dashboard-operations-grid { grid-template-columns: minmax(0, 1fr); }
  .dashboard-operations-grid > * { min-width: 0; }
  .health-card .progress-block { grid-template-columns: minmax(0, 1fr); justify-items:center; }
  .health-legend { width:100%; }
}
/* ===== END pages/dashboard.css ===== */

/* ===== BEGIN pages/accounting.css ===== */
/*
 * ARBS stylesheet: pages/accounting.css
 * Purpose: Accounting dashboard, recent expenses and accounting periods.
 * Architecture: Page layer; accounting-only selectors.
 */

.accounting-page {
   display:grid;
   gap:1.35rem
}
 .accounting-hero {
   display:flex;
   align-items:flex-end;
   justify-content:space-between;
   gap:1.5rem
}
 .accounting-hero-copy {
   max-width:780px
}
 .accounting-eyebrow {
   display:block;
   margin-bottom:.32rem;
   color:var(--brand);
   font-size:.7rem;
   font-weight:850;
   letter-spacing:.09em;
   text-transform:uppercase
}
 .accounting-hero h2 {
   margin:0;
   color:var(--text-strong);
   font-size:1.5rem;
   letter-spacing:-.025em
}
 .accounting-hero p {
   margin:.45rem 0 0;
   color:var(--muted);
   line-height:1.6
}
 .accounting-hero-actions {
   flex:0 0 auto
}
 .accounting-metrics {
   margin:0
}
 .accounting-module-section {
   display:grid;
   gap:1rem
}
 .accounting-section-heading h3 {
   margin:0;
   color:var(--text-strong);
   font-size:1.15rem
}
 .accounting-section-heading p {
   margin:.35rem 0 0;
   color:var(--muted);
   font-size:.85rem
}
 .accounting-links .report-card {
   min-height:112px;
   box-sizing:border-box
}
 .accounting-activity-grid {
   display:grid;
   grid-template-columns:minmax(0,2fr) minmax(320px,1fr);
   gap:1.15rem;
   align-items:stretch
}
 .accounting-card {
   min-width:0;
   overflow:hidden;
   border:1px solid var(--border);
   border-radius:18px;
   background:var(--surface);
   box-shadow:var(--shadow-sm)
}
 .accounting-card-header {
   display:flex;
   align-items:center;
   justify-content:space-between;
   gap:1rem;
   padding:1.2rem 1.25rem;
   border-bottom:1px solid var(--border);
   background:linear-gradient(180deg,color-mix(in srgb,var(--brand) 4%,var(--surface)),var(--surface))
}
 .accounting-card-heading {
   display:grid;
   grid-template-columns:48px minmax(0,1fr);
   gap:.85rem;
   align-items:center;
   min-width:0
}
 .accounting-card-icon {
   display:grid;
   place-items:center;
   width:48px;
   height:48px;
   border-radius:13px;
   background:var(--brand-soft);
   color:var(--brand)
}
 .accounting-card-icon svg {
   width:24px;
   height:24px
}
 .accounting-card-heading h3 {
   margin:0;
   color:var(--text-strong);
   font-size:1.08rem
}
 .accounting-card-heading p {
   margin:.3rem 0 0;
   color:var(--muted);
   font-size:.79rem;
   line-height:1.45
}
 .accounting-view-all {
   flex:0 0 auto;
   white-space:nowrap
}
 .accounting-table-wrap {
   overflow-x:auto
}
 .accounting-table {
   width:100%;
   min-width:780px;
   table-layout:auto;
   border-collapse:collapse
}
 .accounting-table th {
   padding:.8rem 1rem;
   background:var(--surface-2);
   color:var(--muted);
   font-size:.69rem;
   font-weight:850;
   letter-spacing:.055em;
   text-transform:uppercase;
   white-space:nowrap
}
 .accounting-table td {
   padding:1rem;
   border-top:1px solid var(--border);
   vertical-align:middle
}
 .accounting-table tbody tr:first-child td {
   border-top:0
}
 .accounting-table tbody tr:hover {
   background:color-mix(in srgb,var(--brand) 4%,transparent)
}
 .accounting-table .numeric {
   text-align:right;
   font-variant-numeric:tabular-nums;
   white-space:nowrap
}
 .accounting-supplier-name {
   color:var(--text-strong);
   font-weight:700
}
 .accounting-amount {
   color:var(--text-strong);
   font-weight:750
}
 .accounting-balance {
   color:var(--text-strong);
   font-weight:850
}
 .accounting-periods-card {
   display:flex;
   flex-direction:column
}
 .accounting-card-header--stacked {
   align-items:flex-start
}
 .accounting-period-list {
   display:grid;
   flex:1;
   padding:.7rem 1rem
}
 .accounting-period-item {
   display:grid;
   grid-template-columns:48px minmax(0,1fr) auto;
   gap:.8rem;
   align-items:center;
   padding:.85rem .4rem;
   border-bottom:1px solid var(--border);
   color:inherit;
   text-decoration:none
}
 .accounting-period-item:last-child {
   border-bottom:0
}
 .accounting-period-item:hover {
   background:var(--surface-2)
}
 .accounting-period-month {
   display:grid;
   place-items:center;
   align-content:center;
   width:48px;
   height:48px;
   border:1px solid var(--border);
   border-radius:12px;
   background:var(--surface-2);
   text-align:center
}
 .accounting-period-month strong {
   color:var(--brand);
   font-size:.82rem;
   line-height:1
}
 .accounting-period-month small {
   margin-top:.25rem;
   color:var(--muted);
   font-size:.62rem
}
 .accounting-period-copy {
   min-width:0
}
 .accounting-period-copy strong,.accounting-period-copy small {
   display:block
}
 .accounting-period-copy strong {
   color:var(--text-strong);
   font-size:.84rem;
   overflow-wrap:anywhere
}
 .accounting-period-copy small {
   margin-top:.25rem;
   color:var(--muted);
   font-size:.7rem;
   line-height:1.35
}
 .accounting-period-status {
   display:inline-flex;
   align-items:center;
   min-height:27px;
   padding:.28rem .55rem;
   border:1px solid var(--success-border);
   border-radius:999px;
   background:var(--success-soft);
   color:var(--success);
   font-size:.68rem;
   font-weight:800
}
 .accounting-card-footer {
   padding:1rem 1.2rem;
   border-top:1px solid var(--border);
   background:var(--surface-2)
}
 .accounting-period-action {
   width:100%;
   box-sizing:border-box
}
 .accounting-empty {
   display:grid;
   justify-items:center;
   gap:.35rem;
   padding:2rem 1rem;
   text-align:center
}
 .accounting-empty strong {
   color:var(--text-strong)
}
 .accounting-empty span {
   max-width:420px;
   color:var(--muted);
   font-size:.8rem;
   line-height:1.5
}
 .accounting-empty--periods {
   align-content:center;
   min-height:150px
}
 .accounting-empty .text-link {
   margin-top:.25rem
}
 @media(max-width:1100px) {
   .accounting-activity-grid {
     grid-template-columns:1fr
  }
   .accounting-periods-card {
     min-height:0
  }

}
 @media(max-width:760px) {
   .accounting-page {
     gap:1rem
  }
   .accounting-hero {
     align-items:stretch;
     flex-direction:column
  }
   .accounting-hero-actions {
     display:grid;
     grid-template-columns:minmax(0,1fr)
  }
   .accounting-activity-grid {
     grid-template-columns:minmax(0,1fr)
  }
   .accounting-activity-grid > *, .accounting-hero-actions > * {
     min-width:0
  }
   .accounting-hero-actions .button {
     width:100%;
     box-sizing:border-box
  }
   .accounting-card-header {
     align-items:flex-start;
     flex-direction:column
  }
   .accounting-view-all {
     width:100%;
     box-sizing:border-box
  }
   .accounting-card-heading {
     grid-template-columns:44px minmax(0,1fr)
  }
   .accounting-card-icon {
     width:44px;
     height:44px
  }
   .accounting-table th,.accounting-table td {
     padding:.8rem
  }
   .accounting-period-list {
     padding:.55rem .8rem
  }

}
 @media(max-width:520px) {
   .accounting-period-item {
     grid-template-columns:44px minmax(0,1fr)
  }
   .accounting-period-month {
     width:44px;
     height:44px
  }
   .accounting-period-status {
     grid-column:2;
     justify-self:start
  }

}
/* ===== END pages/accounting.css ===== */

/* ===== BEGIN pages/people.css ===== */
/*
 * ARBS stylesheet: pages/people.css
 * Purpose: User accounts, Parties, invitations and relationship administration.
 * Architecture: People-management selectors only.
 */


 .people-page-header {
   display:flex;
   align-items:flex-end;
   justify-content:space-between;
   gap:20px;
   margin-bottom:22px
}
 .people-page-header h2 {
   margin:4px 0 5px;
   color:var(--text-strong);
   font-size:27px;
   letter-spacing:-.03em
}
 .people-page-header p {
   max-width:850px;
   margin:0;
   color:var(--muted);
   line-height:1.55
}
 .people-card {
   overflow:hidden;
   border:1px solid var(--border);
   border-radius:16px;
   background:var(--surface);
   box-shadow:var(--shadow-sm)
}
 .people-card__header {
   display:flex;
   align-items:center;
   justify-content:space-between;
   gap:16px;
   padding:21px 23px;
   border-bottom:1px solid var(--border);
   background:linear-gradient(180deg,var(--surface),var(--surface-2))
}
 .people-card__header h3 {
   margin:2px 0 3px;
   color:var(--text-strong);
   font-size:18px
}
 .people-card__header p {
   margin:0;
   color:var(--muted);
   font-size:13px;
   line-height:1.45
}
 .people-card__body {
   padding:22px 23px
}

 .context-note {
   display:grid;
   gap:4px;
   margin-top:16px;
   padding:14px 16px;
   border:1px solid var(--border);
   border-radius:12px;
   background:var(--surface-2);
   color:var(--muted)
}
 .context-note strong {
   color:var(--text-strong)
}


.user-management-layout {
   display:grid;
   grid-template-columns:minmax(0,1fr) minmax(300px,.34fr);
   gap:20px;
   align-items:start
}
 .user-management-main {
   display:grid;
   gap:20px
}
 .user-management-aside {
   min-width:0
}







 .security-action .button {
   margin-top:12px
}
 .checkbox-panel {
   padding:16px;
   border:1px solid var(--border);
   border-radius:12px;
   background:var(--surface-2)
}
 .checkbox-panel ul {
   display:grid;
   grid-template-columns:repeat(2,minmax(0,1fr));
   gap:9px 16px;
   margin:10px 0 0;
   padding:0;
   list-style:none
}
 .checkbox-panel label {
   display:flex;
   align-items:center;
   gap:8px;
   font-weight:600
}
 .user-account-hero {
   display:grid;
   grid-template-columns:64px minmax(0,1fr) auto;
   gap:17px;
   align-items:center;
   padding:22px 24px;
   margin-bottom:20px
}
 .user-account-avatar, .party-identity-avatar {
   display:grid;
   place-items:center;
   border-radius:16px;
   background:var(--brand-soft);
   color:var(--brand-deep);
   font-weight:900;
   text-transform:uppercase
}
 .user-account-avatar {
   width:64px;
   height:64px;
   font-size:20px
}
 .user-account-identity h2 {
   margin:0;
   font-size:25px
}
 .user-account-identity p {
   margin:5px 0 0;
   color:var(--muted);
   overflow-wrap:anywhere
}
 .user-account-actions {
   display:flex;
   align-items:center;
   justify-content:flex-end;
   gap:8px;
   flex-wrap:wrap
}
 .user-account-actions form {
   margin:0
}
 .user-account-grid {
   display:grid;
   grid-template-columns:minmax(0,1.35fr) minmax(340px,.65fr);
   gap:20px;
   align-items:start
}
 .user-account-side-stack {
   display:grid;
   min-width:0;
   gap:20px
}
 .people-card--compact .people-card__header {
   padding:17px 19px
}
 .people-card--compact .people-card__body {
   padding:17px 19px
}
 .people-card--compact .compact-definition-list {
   margin-bottom:14px
}
 .people-card--compact .compact-definition-list:last-child {
   margin-bottom:0
}
 .people-definition-list, .compact-definition-list {
   margin:0
}
 .people-definition-list>div {
   display:grid;
   grid-template-columns:minmax(145px,.38fr) minmax(0,1fr);
   gap:18px;
   padding:14px 23px;
   border-bottom:1px solid var(--border)
}
 .people-definition-list>div:last-child {
   border-bottom:0
}
 .people-definition-list dt, .compact-definition-list dt {
   color:var(--muted);
   font-size:13px;
   font-weight:700
}
 .people-definition-list dd, .compact-definition-list dd {
   min-width:0;
   margin:0;
   overflow-wrap:anywhere
}
 .token-chip, .plot-chip {
   display:inline-flex;
   align-items:center;
   margin:2px 5px 2px 0;
   padding:4px 8px;
   border-radius:999px;
   background:var(--surface-3);
   color:var(--text);
   font-size:12px;
   font-weight:700;
   text-decoration:none
}
 .plot-chip:hover {
   background:var(--brand-soft);
   color:var(--brand-deep)
}
 .party-identity-summary {
   display:flex;
   align-items:center;
   gap:12px;
   margin-bottom:17px
}
 .party-identity-avatar {
   width:44px;
   height:44px
}
 .party-identity-summary>div:last-child {
   display:grid
}
 .party-identity-summary span {
   color:var(--muted);
   font-size:13px
}
 .compact-definition-list {
   margin-bottom:18px
}
 .compact-definition-list>div {
   display:grid;
   grid-template-columns:minmax(112px,.42fr) minmax(0,1fr);
   gap:12px;
   padding:10px 0;
   border-bottom:1px solid var(--border)
}
 .compact-definition-list>div:last-child {
   border-bottom:0
}
 .communication-status-list>div {
   padding-block:8px
}

 .security-form-layout {
   display:grid;
   grid-template-columns:minmax(0,1.35fr) minmax(280px,.65fr);
   gap:20px;
   align-items:start;
   max-width:1100px
}
 .password-help {
   margin-top:4px;
   padding:12px 14px;
   border-radius:10px;
   background:var(--surface-2);
   color:var(--muted);
   font-size:13px
}
 .password-help ul {
   margin:6px 0 0;
   padding-left:18px
}
 .filter-card-separated {
   margin-bottom:20px
}



 .people-table th {
   background:var(--surface-2);
   color:var(--muted);
   font-size:11px;
   letter-spacing:.06em;
   text-transform:uppercase
}
 .people-table td {
   padding-top:15px;
   padding-bottom:15px;
   vertical-align:middle
}
 .party-col-name {
   width:25%
}
 .party-col-contact {
   width:26%
}
 .party-col-login {
   width:18%
}
 .party-col-access {
   width:23%
}
 .party-col-actions {
   width:8%
}
 .party-access-cell {
   min-width:180px
}
 @media (max-width:1100px) {
   .user-management-layout, .user-account-grid, .security-form-layout {
     grid-template-columns:1fr
  }
   .user-account-hero {
     grid-template-columns:58px minmax(0,1fr)
  }
   .user-account-actions {
     grid-column:1/-1;
     justify-content:flex-start
  }

}
 @media (max-width:700px) {
   .people-page-header, .parties-page-header {
     align-items:stretch;
     flex-direction:column
  }
   .people-card__header, .people-card__body {
     padding-left:17px;
     padding-right:17px
  }
   .user-management-layout {
     grid-template-columns:1fr
  }
   .checkbox-panel ul {
     grid-template-columns:1fr
  }
   .user-account-hero {
     grid-template-columns:46px minmax(0,1fr);
     padding:17px
  }
   .user-account-avatar {
     width:46px;
     height:46px;
     border-radius:13px;
     font-size:15px
  }
   .user-account-actions {
     align-items:stretch;
     flex-direction:column
  }
   .user-account-actions .button, .user-account-actions form, .user-account-actions form button {
     width:100%;
     justify-content:center
  }
   .people-definition-list>div {
     grid-template-columns:1fr;
     gap:4px;
     padding-inline:17px
  }
   .compact-definition-list>div {
     grid-template-columns:1fr;
     gap:4px
  }

}

/* Parties directory and Party detail workflow */
 .parties-list-filter-grid {
   grid-template-columns:minmax(280px,2fr) repeat(2,minmax(170px,1fr)) auto;
   align-items:end
}
 .parties-list-filter-grid .field-group {
   align-self:end
}
 .parties-list-filter-grid input,.parties-list-filter-grid select {
   height:46px;
   box-sizing:border-box
}
 .parties-filter-actions {
   align-items:center;
   align-self:end;
   flex-wrap:nowrap
}
 .parties-filter-actions .button {
   min-width:112px;
   height:46px;
   box-sizing:border-box
}


 .parties-table th,.parties-table td {
   vertical-align:middle
}
 .parties-table .plot-chip {
   white-space:nowrap
}
 .party-row-action .button {
   min-width:72px
}
.party-detail-page {
   display:grid;
   gap:20px
}
 .party-detail-page>.breadcrumb {
   margin-bottom:-6px
}
 .party-detail-hero {
   display:grid;
   grid-template-columns:64px minmax(0,1fr) auto;
   gap:18px;
   align-items:center;
   padding:22px 24px
}
 .party-detail-avatar {
   display:grid;
   place-items:center;
   width:64px;
   height:64px;
   border-radius:17px;
   background:var(--brand-soft);
   color:var(--brand-deep);
   font-size:20px;
   font-weight:900;
   text-transform:uppercase
}
 .party-detail-identity {
   min-width:0
}
 .party-detail-identity h2 {
   margin:2px 0 4px;
   color:var(--text-strong);
   font-size:26px;
   letter-spacing:-.025em
}
 .party-detail-identity p {
   max-width:760px;
   margin:0;
   color:var(--muted);
   line-height:1.5
}
 .party-detail-actions {
   display:flex;
   align-items:center;
   justify-content:flex-end;
   gap:9px;
   flex-wrap:nowrap
}
 .party-detail-actions .button {
   min-width:112px;
   height:42px;
   box-sizing:border-box
}
 .party-detail-layout {
   display:grid;
   grid-template-columns:minmax(0,1.55fr) minmax(300px,.55fr);
   gap:20px;
   align-items:start
}
 .party-detail-main,.party-detail-sidebar {
   display:grid;
   gap:20px;
   min-width:0
}
 .party-panel {
   min-width:0;
   overflow:hidden
}
 .party-panel .staff-card-heading {
   min-height:92px;
   box-sizing:border-box
}
 .party-panel-body {
   padding:22px 24px
}
 .party-detail-grid {
   display:grid;
   grid-template-columns:repeat(2,minmax(0,1fr));
   gap:0;
   margin:0;
   border:1px solid var(--border);
   border-radius:12px;
   overflow:hidden
}
 .party-detail-grid>div {
   min-width:0;
   padding:16px 18px;
   background:var(--surface)
}
 .party-detail-grid>div:nth-child(odd) {
   border-right:1px solid var(--border)
}
 .party-detail-grid>div:nth-child(n+3) {
   border-top:1px solid var(--border)
}
 .party-detail-grid>div.span-full {
   grid-column:1/-1;
   border-right:0
}
 .party-detail-grid dt {
   margin-bottom:5px;
   color:var(--muted);
   font-size:12px;
   font-weight:800;
   letter-spacing:.04em;
   text-transform:uppercase
}
 .party-detail-grid dd {
   min-width:0;
   margin:0;
   color:var(--text);
   font-weight:600;
   line-height:1.55;
   overflow-wrap:anywhere
}
 .party-section-heading {
   align-items:center
}
 .party-section-heading>.button {
   flex:0 0 auto;
   white-space:nowrap
}
 .party-relationship-table {
   min-width:760px
}
 .party-relationship-table th,.party-relationship-table td {
   vertical-align:middle
}
 .party-linked-account {
   display:grid;
   gap:16px
}
 .party-linked-account>div {
   display:grid;
   gap:3px;
   padding:15px;
   border:1px solid var(--border);
   border-radius:11px;
   background:var(--surface-2)
}
 .party-linked-account strong {
   color:var(--text-strong)
}
 .party-linked-account span {
   color:var(--muted);
   font-size:13px
}
 .party-phone-list {
   display:grid;
   gap:0;
   padding:8px 22px
}
 .party-phone-row {
   display:flex;
   align-items:center;
   justify-content:space-between;
   gap:14px;
   padding:14px 0;
   border-bottom:1px solid var(--border)
}
 .party-phone-row:last-child {
   border-bottom:0
}
 .party-phone-row>div {
   display:grid;
   min-width:0
}
 .party-phone-row strong {
   overflow-wrap:anywhere
}
 .party-phone-row span {
   color:var(--muted);
   font-size:13px
}
 .party-phone-row .button {
   flex:0 0 auto;
   min-width:62px
}
@media(max-width:1100px) {
   .parties-list-filter-grid {
     grid-template-columns:repeat(2,minmax(0,1fr))
  }
   .parties-list-filter-grid .staff-filter-search,.parties-list-filter-grid .parties-filter-actions {
     grid-column:1/-1
  }
   .party-detail-layout {
     grid-template-columns:1fr
  }
   .party-detail-sidebar {
     grid-template-columns:repeat(2,minmax(0,1fr))
  }

}
 @media(max-width:700px) {
   .parties-list-filter-grid {
     grid-template-columns:1fr
  }
   .parties-list-filter-grid .staff-filter-search,.parties-list-filter-grid .parties-filter-actions {
     grid-column:auto
  }
   .parties-filter-actions {
     flex-wrap:wrap
  }
   .parties-filter-actions .button {
     flex:1
  }
   .party-detail-hero {
     grid-template-columns:52px minmax(0,1fr);
     padding:18px
  }
   .party-detail-avatar {
     width:52px;
     height:52px;
     border-radius:14px;
     font-size:17px
  }
   .party-detail-actions {
     grid-column:1/-1;
     justify-content:stretch
  }
   .party-detail-actions .button {
     flex:1;
     min-width:0
  }
   .party-detail-sidebar {
     grid-template-columns:1fr
  }
   .party-detail-grid {
     grid-template-columns:1fr
  }
   .party-detail-grid>div,.party-detail-grid>div:nth-child(odd) {
     border-right:0
  }
   .party-detail-grid>div:nth-child(n+2) {
     border-top:1px solid var(--border)
  }
   .party-panel .staff-card-heading {
     min-height:0
  }
   .party-section-heading {
     align-items:stretch
  }
   .party-section-heading>.button {
     width:100%
  }
   .party-phone-list {
     padding-inline:17px
  }

}


/* Party register table sizing remains domain-owned. */
.parties-table {
  min-width: 1080px;
  table-layout: auto;
}

.parties-table th,
.parties-table td {
  min-width: 0;
  vertical-align: middle;
}


.party-row-action {
  white-space: nowrap;
}

/* People-domain forms: user identity, phone and Party account composition. */
.phone-number-grid,
.user-identity-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
}

.phone-number-grid > *,
.user-identity-grid > *,
.user-identity-field,
.user-identity-field--username,
.user-identity-field--first_name {
  width: 100%;
  min-width: 0;
}

.phone-number-grid input,
.phone-number-grid select,
.user-identity-field input,
.user-identity-field select {
  width: 100%;
  min-height: 46px;
  margin: 0;
}

.phone-number-grid label,
.user-identity-field label {
  display: flex;
  align-items: center;
  min-height: 18px;
}

.phone-number-grid .help-text {
  min-height: 35px;
}

.phone-number-grid > .field-group:nth-child(n + 3) .help-text:empty {
  display: none;
}

.users-filter-grid--aligned {
  align-items: end;
}

.users-filter-grid--aligned .field-group {
  align-self: end;
}

.users-filter-actions {
  align-self: end;
  min-height: 46px;
}

.party-form-grid,
.party-account-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
  align-items: start;
}

.party-form-grid > *,
.party-account-row > * {
  min-width: 0;
}

.party-form-grid .span-full,
.party-account-row {
  grid-column: 1 / -1;
}

@media (max-width: 1100px) {
  .users-filter-grid--aligned .users-search-field,
  .users-filter-grid--aligned .users-filter-actions {
    grid-column: 1 / -1;
  }

  .party-form-grid,
  .party-account-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .phone-number-grid,
  .user-identity-grid,
  .party-form-grid,
  .party-account-row {
    grid-template-columns: minmax(0, 1fr);
    gap: 18px;
  }

  .users-filter-grid--aligned .users-search-field,
  .users-filter-grid--aligned .users-filter-actions {
    grid-column: auto;
  }
}


/* User detail: consolidated operational overview. */
.user-account-overview {
  margin-bottom:20px
}
.user-account-overview__header {
  align-items:flex-start
}
.user-account-overview__meta {
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap:7px;
  flex-wrap:wrap
}
.user-account-summary-grid {
  display:grid;
  grid-template-columns:minmax(230px,.85fr) minmax(330px,1.35fr) minmax(260px,1fr);
  align-items:stretch
}
.user-account-summary-section {
  min-width:0;
  padding:21px 23px 22px
}
.user-account-summary-section + .user-account-summary-section {
  border-left:1px solid var(--border)
}
.user-account-summary-heading {
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:12px;
  min-height:43px;
  margin-bottom:14px
}
.user-account-summary-heading h4,
.user-property-access-heading h4 {
  margin:2px 0 0;
  color:var(--text-strong);
  font-size:16px;
  letter-spacing:-.01em
}
.user-account-summary-kicker {
  display:block;
  color:var(--muted);
  font-size:10px;
  font-weight:800;
  letter-spacing:.09em;
  text-transform:uppercase
}
.user-account-summary-list {
  margin:0
}
.user-account-summary-list>div {
  display:grid;
  grid-template-columns:minmax(98px,.4fr) minmax(0,1fr);
  gap:11px;
  padding:9px 0;
  border-bottom:1px solid var(--border)
}
.user-account-summary-list>div:last-child {
  border-bottom:0
}
.user-account-summary-list dt {
  color:var(--muted);
  font-size:12px;
  font-weight:700
}
.user-account-summary-list dd {
  min-width:0;
  margin:0;
  font-size:13px;
  overflow-wrap:anywhere
}
.user-account-inline-note {
  display:grid;
  gap:2px;
  margin-top:13px;
  padding:11px 12px;
  border:1px solid var(--border);
  border-radius:10px;
  background:var(--surface-2)
}
.user-account-inline-note strong {
  color:var(--text-strong);
  font-size:12px
}
.user-account-inline-note span {
  color:var(--muted);
  font-size:11px;
  line-height:1.4
}
.user-account-party-row {
  display:flex;
  align-items:center;
  gap:11px;
  margin-bottom:6px
}
.user-account-party-copy {
  display:grid;
  min-width:0;
  gap:2px
}
.user-account-party-copy strong {
  overflow-wrap:anywhere
}
.user-account-party-copy span {
  color:var(--muted);
  font-size:12px
}
.user-account-summary-list__phones {
  align-items:start
}
.user-account-phone-row {
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:10px;
  padding:7px 0
}
.user-account-phone-row:first-child {
  padding-top:0
}
.user-account-phone-row:last-child {
  padding-bottom:0
}
.user-account-phone-row>div:first-child {
  display:grid;
  min-width:0;
  gap:2px
}
.user-account-phone-row .badge {
  margin-left:5px
}
.user-account-phone-actions {
  display:flex;
  align-items:center;
  gap:8px;
  flex:0 0 auto
}
.user-account-phone-actions form {
  margin:0
}
.user-account-section-actions {
  margin-top:13px
}
.user-account-empty-inline {
  display:grid;
  gap:6px;
  padding:14px;
  border:1px dashed var(--border);
  border-radius:11px;
  background:var(--surface-2)
}
.user-account-empty-inline span {
  color:var(--muted);
  font-size:13px;
  line-height:1.45
}
.user-account-empty-inline .button {
  justify-self:start;
  margin-top:4px
}
.communication-readiness-grid {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:8px
}
.communication-readiness-item {
  display:grid;
  min-width:0;
  gap:3px;
  padding:10px 11px;
  border:1px solid var(--border);
  border-radius:10px;
  background:var(--surface-2)
}
.communication-readiness-item:first-child {
  grid-column:1/-1
}
.communication-readiness-item span {
  color:var(--muted);
  font-size:10px;
  font-weight:800;
  letter-spacing:.05em;
  text-transform:uppercase
}
.communication-readiness-item strong {
  min-width:0;
  color:var(--text-strong);
  font-size:12px;
  overflow-wrap:anywhere
}
.user-property-access-section {
  border-top:1px solid var(--border)
}
.user-property-access-heading {
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:16px;
  padding:19px 23px 14px
}
.user-property-access-heading p {
  margin:4px 0 0;
  color:var(--muted);
  font-size:13px;
  line-height:1.45
}
.user-property-access-table {
  border-top:1px solid var(--border)
}
.user-property-access-table table {
  min-width:760px
}

@media (max-width:1200px) {
  .user-account-summary-grid {
    grid-template-columns:repeat(2,minmax(0,1fr))
  }
  .user-account-summary-section--communications {
    grid-column:1/-1;
    border-left:0;
    border-top:1px solid var(--border)
  }
  .user-account-summary-section--identity {
    border-left:1px solid var(--border)
  }
  .communication-readiness-grid {
    grid-template-columns:repeat(5,minmax(0,1fr))
  }
  .communication-readiness-item:first-child {
    grid-column:auto
  }
}
@media (max-width:760px) {
  .user-account-overview__header {
    align-items:flex-start;
    flex-direction:column
  }
  .user-account-overview__meta {
    justify-content:flex-start
  }
  .user-account-summary-grid {
    grid-template-columns:1fr
  }
  .user-account-summary-section + .user-account-summary-section,
  .user-account-summary-section--identity,
  .user-account-summary-section--communications {
    grid-column:auto;
    border-left:0;
    border-top:1px solid var(--border)
  }
  .communication-readiness-grid {
    grid-template-columns:repeat(2,minmax(0,1fr))
  }
  .communication-readiness-item:first-child {
    grid-column:1/-1
  }
}
@media (max-width:520px) {
  .user-account-summary-section {
    padding:17px 18px 18px
  }
  .user-account-summary-list>div {
    grid-template-columns:1fr;
    gap:3px
  }
  .user-account-phone-row {
    display:grid
  }
  .user-account-phone-actions {
    justify-content:flex-start
  }
  .user-property-access-heading {
    padding:16px 18px 12px
  }
  .communication-readiness-grid {
    grid-template-columns:1fr
  }
  .communication-readiness-item:first-child {
    grid-column:auto
  }
}

/* Party detail and contact workspace: consolidated operational layouts. */
.party-profile-page,
.contact-party-page {
  display:grid;
  gap:18px;
  min-width:0;
}
.party-profile-page>.breadcrumb,
.contact-party-page>.breadcrumb {
  margin-bottom:-3px;
}
.party-profile-hero {
  grid-template-columns:auto minmax(0,1fr) auto auto;
  align-items:center;
}
.party-profile-hero-meta,
.contact-party-hero__meta {
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap:7px;
  flex-wrap:wrap;
}
.party-profile-overview,
.contact-party-workspace {
  min-width:0;
  overflow:hidden;
}
.party-profile-overview__header,
.contact-party-workspace__header {
  align-items:flex-start;
}
.party-profile-summary-grid {
  display:grid;
  grid-template-columns:minmax(270px,1fr) minmax(310px,1.15fr) minmax(270px,.9fr);
  align-items:stretch;
}
.party-profile-summary-section {
  min-width:0;
  padding:21px 23px 22px;
}
.party-profile-summary-section + .party-profile-summary-section {
  border-left:1px solid var(--border);
}
.party-profile-summary-heading,
.contact-party-section-heading,
.contact-party-conversations__heading {
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:12px;
  margin-bottom:13px;
}
.party-profile-summary-heading h4,
.contact-party-section-heading h4,
.contact-party-conversations__heading h4,
.party-profile-access-heading h4 {
  margin:2px 0 0;
  color:var(--text-strong);
  font-size:16px;
  letter-spacing:-.01em;
}
.contact-party-section-heading p,
.contact-party-conversations__heading p,
.party-profile-access-heading p {
  margin:4px 0 0;
  color:var(--muted);
  font-size:13px;
  line-height:1.45;
}
.party-profile-summary-list {
  margin:0;
}
.party-profile-summary-list>div {
  display:grid;
  grid-template-columns:minmax(102px,.42fr) minmax(0,1fr);
  gap:11px;
  padding:9px 0;
  border-bottom:1px solid var(--border);
}
.party-profile-summary-list>div:last-child {
  border-bottom:0;
}
.party-profile-summary-list dt {
  color:var(--muted);
  font-size:12px;
  font-weight:700;
}
.party-profile-summary-list dd {
  min-width:0;
  margin:0;
  font-size:13px;
  overflow-wrap:anywhere;
}
.party-profile-phone-list {
  display:grid;
  gap:0;
}
.party-profile-phone-row {
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:12px;
  padding:10px 0;
  border-bottom:1px solid var(--border);
}
.party-profile-phone-row:first-child { padding-top:0; }
.party-profile-phone-row:last-child { border-bottom:0; padding-bottom:0; }
.party-profile-phone-row>div {
  display:grid;
  min-width:0;
  gap:2px;
}
.party-profile-phone-row strong { overflow-wrap:anywhere; }
.party-profile-phone-row span {
  color:var(--muted);
  font-size:12px;
  line-height:1.4;
}
.party-profile-account {
  display:grid;
  gap:13px;
}
.party-profile-account-identity {
  display:flex;
  align-items:center;
  gap:10px;
  min-width:0;
}
.party-profile-account-identity>div:last-child {
  display:grid;
  min-width:0;
  gap:2px;
}
.party-profile-account-identity span {
  color:var(--muted);
  font-size:12px;
}
.party-profile-summary-list--compact>div {
  grid-template-columns:minmax(72px,.35fr) minmax(0,1fr);
}
.party-profile-empty-inline {
  display:grid;
  gap:7px;
  padding:14px;
  border:1px dashed var(--border);
  border-radius:11px;
  background:var(--surface-2);
}
.party-profile-empty-inline span {
  color:var(--muted);
  font-size:13px;
  line-height:1.45;
}
.party-profile-inline-actions {
  display:flex;
  align-items:center;
  gap:8px;
  flex-wrap:wrap;
  margin-top:3px;
}
.party-profile-access-section,
.contact-party-conversations {
  border-top:1px solid var(--border);
}
.party-profile-access-heading,
.contact-party-conversations__heading {
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:16px;
  padding:18px 23px 14px;
  margin:0;
}
.party-profile-access-table,
.contact-party-conversations__table {
  border-top:1px solid var(--border);
}
.party-profile-access-table table { min-width:800px; }

.contact-party-hero {
  display:grid;
  grid-template-columns:auto minmax(0,1fr) auto auto;
  align-items:center;
  gap:17px;
  padding:19px 21px;
}
.contact-party-hero__identity {
  min-width:0;
}
.contact-party-hero__identity h2 {
  margin:2px 0 4px;
  color:var(--text-strong);
  font-size:24px;
  letter-spacing:-.025em;
}
.contact-party-hero__identity p {
  max-width:720px;
  margin:0;
  color:var(--muted);
  font-size:13px;
  line-height:1.5;
}
.contact-party-compose-grid {
  display:grid;
  grid-template-columns:minmax(0,1.55fr) minmax(300px,.65fr);
}
.contact-party-composer,
.contact-party-context {
  min-width:0;
  padding:21px 23px 22px;
}
.contact-party-context {
  border-left:1px solid var(--border);
  background:var(--surface-2);
}
.contact-party-form {
  display:grid;
  gap:16px;
}
.contact-party-form textarea {
  min-height:180px;
  resize:vertical;
}
.contact-party-form-actions {
  margin-top:0;
  padding-top:0;
}
.contact-readiness-grid {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:8px;
}
.contact-readiness-item {
  display:grid;
  min-width:0;
  gap:3px;
  padding:10px 11px;
  border:1px solid var(--border);
  border-radius:10px;
  background:var(--surface);
}
.contact-readiness-item--wide { grid-column:1/-1; }
.contact-readiness-item>span {
  color:var(--muted);
  font-size:10px;
  font-weight:800;
  letter-spacing:.05em;
  text-transform:uppercase;
}
.contact-readiness-item strong {
  min-width:0;
  color:var(--text-strong);
  font-size:12px;
  overflow-wrap:anywhere;
}
.contact-readiness-item small {
  color:var(--muted);
  font-size:11px;
}
.contact-party-phone-block {
  display:grid;
  gap:8px;
  margin-top:16px;
  padding-top:15px;
  border-top:1px solid var(--border);
}
.contact-party-phone-list {
  display:grid;
  gap:0;
}
.contact-party-phone-list>div {
  display:grid;
  gap:2px;
  padding:8px 0;
  border-bottom:1px solid var(--border);
}
.contact-party-phone-list>div:last-child { border-bottom:0; }
.contact-party-phone-list strong {
  font-size:13px;
  overflow-wrap:anywhere;
}
.contact-party-phone-list span {
  color:var(--muted);
  font-size:11px;
}
.contact-party-policy-note {
  display:grid;
  gap:3px;
  margin-top:14px;
  padding:11px 12px;
  border:1px solid var(--border);
  border-radius:10px;
  background:var(--surface);
}
.contact-party-policy-note strong {
  color:var(--text-strong);
  font-size:12px;
}
.contact-party-policy-note span {
  color:var(--muted);
  font-size:11px;
  line-height:1.45;
}
.contact-party-conversations__table table { min-width:760px; }

@media (max-width:1180px) {
  .party-profile-hero,
  .contact-party-hero {
    grid-template-columns:auto minmax(0,1fr) auto;
  }
  .party-profile-hero-meta,
  .contact-party-hero__meta {
    grid-column:2/-1;
    grid-row:2;
    justify-content:flex-start;
  }
  .party-profile-summary-grid {
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
  .party-profile-summary-section--account {
    grid-column:1/-1;
    border-left:0;
    border-top:1px solid var(--border);
  }
  .contact-party-compose-grid {
    grid-template-columns:minmax(0,1.25fr) minmax(280px,.75fr);
  }
}
@media (max-width:820px) {
  .party-profile-summary-grid,
  .contact-party-compose-grid {
    grid-template-columns:1fr;
  }
  .party-profile-summary-section + .party-profile-summary-section,
  .party-profile-summary-section--account,
  .contact-party-context {
    grid-column:auto;
    border-left:0;
    border-top:1px solid var(--border);
  }
  .party-profile-hero,
  .contact-party-hero {
    grid-template-columns:auto minmax(0,1fr);
  }
  .party-profile-hero-meta,
  .contact-party-hero__meta {
    grid-column:1/-1;
  }
  .party-detail-actions,
  .contact-party-hero>.button {
    grid-column:1/-1;
    justify-self:start;
  }
}
@media (max-width:560px) {
  .party-profile-hero,
  .contact-party-hero {
    grid-template-columns:1fr;
    align-items:start;
  }
  .party-detail-avatar {
    width:44px;
    height:44px;
  }
  .party-profile-hero-meta,
  .contact-party-hero__meta,
  .party-detail-actions,
  .contact-party-hero>.button {
    grid-column:auto;
  }
  .party-detail-actions {
    display:grid;
    width:100%;
  }
  .party-detail-actions .button { width:100%; }
  .party-profile-summary-section,
  .contact-party-composer,
  .contact-party-context {
    padding:17px 18px 18px;
  }
  .party-profile-summary-list>div {
    grid-template-columns:1fr;
    gap:3px;
  }
  .party-profile-phone-row { display:grid; }
  .party-profile-access-heading,
  .contact-party-conversations__heading {
    align-items:flex-start;
    flex-direction:column;
    padding:17px 18px 13px;
  }
  .contact-readiness-grid { grid-template-columns:1fr; }
  .contact-readiness-item--wide { grid-column:auto; }
}

/* Party profile refinement: a single dense resident workspace with intentional hierarchy. */
.party-profile-page--refined {
  gap:16px;
}
.party-profile-hero--refined {
  grid-template-columns:auto minmax(0,1fr) auto auto;
  gap:16px;
}
.party-profile-overview--refined {
  overflow:hidden;
}
.party-profile-overview__header--refined {
  padding-bottom:15px;
}
.party-profile-overview__header--refined .user-account-summary-kicker {
  display:block;
  margin-bottom:2px;
}
.party-profile-facts {
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  border-top:1px solid var(--border);
  border-bottom:1px solid var(--border);
  background:var(--surface-2);
}
.party-profile-fact {
  display:grid;
  min-width:0;
  gap:3px;
  padding:12px 16px;
}
.party-profile-fact + .party-profile-fact {
  border-left:1px solid var(--border);
}
.party-profile-fact span {
  color:var(--muted);
  font-size:10px;
  font-weight:800;
  letter-spacing:.05em;
  text-transform:uppercase;
}
.party-profile-fact strong {
  min-width:0;
  color:var(--text-strong);
  font-size:13px;
  line-height:1.35;
  overflow-wrap:anywhere;
}
.party-profile-workspace-grid {
  display:grid;
  grid-template-columns:minmax(0,1.55fr) minmax(260px,.72fr);
  min-width:0;
}
.party-profile-main-section,
.party-profile-account-panel {
  min-width:0;
  padding:20px 23px 22px;
}
.party-profile-account-panel {
  border-left:1px solid var(--border);
  background:color-mix(in srgb,var(--surface-2) 42%,transparent);
}
.party-profile-section-heading {
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:12px;
  margin-bottom:14px;
}
.party-profile-section-heading h4 {
  margin:2px 0 0;
  color:var(--text-strong);
  font-size:16px;
  letter-spacing:-.01em;
}
.party-profile-identity-contact-grid {
  display:grid;
  grid-template-columns:minmax(235px,.82fr) minmax(280px,1.18fr);
  gap:22px;
  align-items:start;
}
.party-profile-summary-list--identity>div {
  grid-template-columns:minmax(88px,.4fr) minmax(0,1fr);
}
.party-profile-phones-panel {
  min-width:0;
  border-left:1px solid var(--border);
  padding-left:22px;
}
.party-profile-phones-heading {
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:12px;
  margin-bottom:8px;
}
.party-profile-phones-heading>div {
  display:grid;
  min-width:0;
  gap:2px;
}
.party-profile-phones-heading strong {
  color:var(--text-strong);
  font-size:13px;
}
.party-profile-phones-heading span {
  color:var(--muted);
  font-size:11px;
  line-height:1.4;
}
.party-profile-phone-list--refined {
  border-top:1px solid var(--border);
}
.party-profile-phone-row--refined {
  padding:11px 0;
}
.party-profile-phone-copy {
  display:grid;
  min-width:0;
  gap:2px;
}
.party-profile-empty-inline--compact {
  padding:12px 0 0;
  border:0;
  border-radius:0;
  background:transparent;
}
.party-profile-account--refined {
  align-content:start;
}
.party-profile-account-list>div {
  padding:8px 0;
}
.party-profile-account-open {
  justify-self:start;
}
.party-profile-account-empty {
  padding:13px;
}
.party-profile-access-section--refined {
  background:var(--surface);
}
.party-profile-access-section--refined .party-profile-access-heading {
  padding-top:17px;
}

@media (max-width:1100px) {
  .party-profile-facts {
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
  .party-profile-fact:nth-child(3) {
    border-left:0;
    border-top:1px solid var(--border);
  }
  .party-profile-fact:nth-child(4) {
    border-top:1px solid var(--border);
  }
  .party-profile-workspace-grid {
    grid-template-columns:1fr;
  }
  .party-profile-account-panel {
    border-left:0;
    border-top:1px solid var(--border);
    background:transparent;
  }
  .party-profile-account--refined {
    grid-template-columns:minmax(200px,.8fr) minmax(260px,1.2fr) auto;
    align-items:center;
    gap:18px;
  }
  .party-profile-account-list {
    display:grid;
    grid-template-columns:repeat(3,minmax(0,1fr));
    gap:0 16px;
  }
  .party-profile-account-list>div {
    display:block;
    border-bottom:0;
  }
  .party-profile-account-list dt {
    margin-bottom:3px;
  }
}

@media (max-width:760px) {
  .party-profile-hero--refined {
    grid-template-columns:auto minmax(0,1fr);
  }
  .party-profile-hero--refined .party-profile-hero-meta,
  .party-profile-hero--refined .party-detail-actions {
    grid-column:1/-1;
    justify-content:flex-start;
  }
  .party-profile-facts {
    grid-template-columns:1fr 1fr;
  }
  .party-profile-identity-contact-grid {
    grid-template-columns:1fr;
    gap:16px;
  }
  .party-profile-phones-panel {
    border-left:0;
    border-top:1px solid var(--border);
    padding:16px 0 0;
  }
  .party-profile-account--refined {
    grid-template-columns:1fr;
  }
  .party-profile-account-list {
    grid-template-columns:1fr 1fr;
  }
  .party-profile-access-heading {
    align-items:flex-start;
    flex-direction:column;
  }
}

@media (max-width:520px) {
  .party-profile-main-section,
  .party-profile-account-panel {
    padding:17px 18px 18px;
  }
  .party-profile-facts {
    grid-template-columns:1fr;
  }
  .party-profile-fact + .party-profile-fact,
  .party-profile-fact:nth-child(3),
  .party-profile-fact:nth-child(4) {
    border-left:0;
    border-top:1px solid var(--border);
  }
  .party-profile-phones-heading {
    align-items:flex-start;
    flex-direction:column;
  }
  .party-profile-account-list {
    grid-template-columns:1fr;
  }
}

/* Contact resident: focused communications workspace. */
.contact-resident-page {
  display:grid;
  gap:16px;
  min-width:0;
}
.contact-resident-page>.breadcrumb { margin-bottom:-2px; }
.contact-resident-workspace {
  min-width:0;
  overflow:hidden;
}
.contact-resident-header {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:20px;
  padding:20px 23px 18px;
}
.contact-resident-person {
  display:flex;
  align-items:center;
  min-width:0;
  gap:14px;
}
.contact-resident-person__text { min-width:0; }
.contact-resident-person__text h2 {
  margin:2px 0 5px;
  color:var(--text-strong);
  font-size:24px;
  letter-spacing:-.025em;
}
.contact-resident-person__meta {
  display:flex;
  flex-wrap:wrap;
  gap:4px 13px;
  color:var(--muted);
  font-size:12px;
}
.contact-resident-person__meta span+span::before {
  content:"•";
  margin-right:13px;
  opacity:.6;
}
.contact-resident-header__actions {
  display:flex;
  flex:none;
  align-items:center;
  gap:8px;
}
.contact-resident-channel-strip {
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  border-top:1px solid var(--border);
  border-bottom:1px solid var(--border);
  background:var(--surface-2);
}
.contact-resident-channel {
  display:grid;
  min-width:0;
  gap:3px;
  padding:13px 17px 14px;
}
.contact-resident-channel+.contact-resident-channel { border-left:1px solid var(--border); }
.contact-resident-channel__label {
  color:var(--muted);
  font-size:10px;
  font-weight:800;
  letter-spacing:.055em;
  text-transform:uppercase;
}
.contact-resident-channel strong {
  min-width:0;
  color:var(--text-strong);
  font-size:13px;
  overflow-wrap:anywhere;
}
.contact-resident-channel small {
  color:var(--muted);
  font-size:11px;
  line-height:1.35;
}
.contact-resident-main-grid {
  display:grid;
  grid-template-columns:minmax(0,1.65fr) minmax(310px,.72fr);
  align-items:stretch;
}
.contact-resident-compose,
.contact-resident-delivery {
  min-width:0;
  padding:23px 24px 24px;
}
.contact-resident-delivery {
  border-left:1px solid var(--border);
  background:var(--surface-2);
}
.contact-resident-section-heading {
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:14px;
  margin-bottom:18px;
}
.contact-resident-section-heading h3,
.contact-resident-conversations__heading h3 {
  margin:2px 0 0;
  color:var(--text-strong);
  font-size:17px;
  letter-spacing:-.012em;
}
.contact-resident-section-heading p,
.contact-resident-conversations__heading p {
  margin:5px 0 0;
  color:var(--muted);
  font-size:13px;
  line-height:1.45;
}
.contact-resident-form {
  display:grid;
  gap:18px;
}
.contact-resident-form-topline {
  display:grid;
  grid-template-columns:minmax(170px,.42fr) minmax(0,1fr);
  gap:15px;
  align-items:start;
}
.contact-resident-message-field {
  min-width:0;
}
.contact-resident-message-label {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
}
.contact-resident-message-label span {
  color:var(--muted);
  font-size:11px;
}
.contact-resident-message-field textarea {
  min-height:235px;
  resize:vertical;
}
.contact-resident-sendbar {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:18px;
  padding-top:16px;
  border-top:1px solid var(--border);
}
.contact-resident-sendbar p {
  max-width:620px;
  margin:0;
  color:var(--muted);
  font-size:12px;
  line-height:1.45;
}
.contact-resident-sendbar .button { flex:none; }
.contact-resident-destination-list {
  margin:0;
}
.contact-resident-destination-list>div {
  display:grid;
  grid-template-columns:minmax(105px,.45fr) minmax(0,1fr);
  gap:12px;
  padding:9px 0;
  border-bottom:1px solid var(--border);
}
.contact-resident-destination-list>div:first-child { padding-top:0; }
.contact-resident-destination-list dt {
  color:var(--muted);
  font-size:11px;
  font-weight:700;
}
.contact-resident-destination-list dd {
  min-width:0;
  margin:0;
  color:var(--text-strong);
  font-size:12px;
  font-weight:650;
  overflow-wrap:anywhere;
}
.contact-resident-phone-section {
  display:grid;
  gap:8px;
  margin-top:17px;
  padding-top:15px;
  border-top:1px solid var(--border);
}
.contact-resident-subheading {
  display:flex;
  align-items:baseline;
  justify-content:space-between;
  gap:10px;
}
.contact-resident-subheading>span {
  color:var(--text-strong);
  font-size:12px;
  font-weight:750;
}
.contact-resident-subheading small {
  color:var(--muted);
  font-size:10px;
}
.contact-resident-phone-list { display:grid; }
.contact-resident-phone-row {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  padding:9px 0;
  border-bottom:1px solid var(--border);
}
.contact-resident-phone-row:last-child { border-bottom:0; }
.contact-resident-phone-row>div {
  display:grid;
  min-width:0;
  gap:2px;
}
.contact-resident-phone-row strong {
  font-size:12px;
  overflow-wrap:anywhere;
}
.contact-resident-phone-row span:not(.badge) {
  color:var(--muted);
  font-size:11px;
}
.contact-resident-empty-inline {
  padding:11px 12px;
  border:1px dashed var(--border);
  border-radius:10px;
  color:var(--muted);
  font-size:12px;
  background:var(--surface);
}
.contact-resident-whatsapp-note {
  display:grid;
  gap:7px;
  margin-top:17px;
  padding:13px 14px;
  border:1px solid var(--border);
  border-radius:12px;
  background:var(--surface);
}
.contact-resident-whatsapp-note>div {
  display:grid;
  gap:2px;
}
.contact-resident-whatsapp-note strong {
  color:var(--text-strong);
  font-size:12px;
}
.contact-resident-whatsapp-note p {
  margin:0;
  color:var(--muted);
  font-size:11px;
  line-height:1.48;
}
.contact-resident-conversations {
  border-top:1px solid var(--border);
}
.contact-resident-conversations__heading {
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:18px;
  padding:19px 23px 15px;
}
.contact-resident-conversations__table {
  border-top:1px solid var(--border);
}
.contact-resident-conversations__table table { min-width:780px; }

@media (max-width:1080px) {
  .contact-resident-main-grid {
    grid-template-columns:minmax(0,1.35fr) minmax(285px,.75fr);
  }
  .contact-resident-channel-strip {
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
  .contact-resident-channel:nth-child(3) {
    border-left:0;
    border-top:1px solid var(--border);
  }
  .contact-resident-channel:nth-child(4) { border-top:1px solid var(--border); }
}
@media (max-width:820px) {
  .contact-resident-main-grid { grid-template-columns:1fr; }
  .contact-resident-delivery {
    border-left:0;
    border-top:1px solid var(--border);
  }
  .contact-resident-form-topline { grid-template-columns:1fr; }
}
@media (max-width:620px) {
  .contact-resident-header {
    align-items:flex-start;
    flex-direction:column;
    padding:18px;
  }
  .contact-resident-person { align-items:flex-start; }
  .contact-resident-header__actions {
    width:100%;
  }
  .contact-resident-header__actions .button { width:100%; }
  .contact-resident-person__meta {
    display:grid;
    gap:2px;
  }
  .contact-resident-person__meta span+span::before { content:none; }
  .contact-resident-channel-strip { grid-template-columns:1fr; }
  .contact-resident-channel+.contact-resident-channel,
  .contact-resident-channel:nth-child(3),
  .contact-resident-channel:nth-child(4) {
    border-left:0;
    border-top:1px solid var(--border);
  }
  .contact-resident-compose,
  .contact-resident-delivery {
    padding:18px;
  }
  .contact-resident-message-label {
    align-items:flex-start;
    flex-direction:column;
    gap:3px;
  }
  .contact-resident-sendbar {
    align-items:stretch;
    flex-direction:column;
  }
  .contact-resident-sendbar .button { width:100%; }
  .contact-resident-destination-list>div { grid-template-columns:1fr; gap:3px; }
  .contact-resident-conversations__heading {
    align-items:flex-start;
    flex-direction:column;
    padding:17px 18px 13px;
  }
}
/* ===== END pages/people.css ===== */

/* ===== BEGIN pages/properties.css ===== */
/*
 * ARBS stylesheet: pages/properties.css
 * Purpose: Property directory, detail, relationships and property forms.
 * Architecture: Page layer; property-only selectors.
 */

.property-heading {
   margin-bottom: 18px;

}
 .property-heading .heading-line {
   display: flex;
   align-items: center;
   flex-wrap: wrap;
   gap: 8px;

}
 .property-heading .heading-line h2 {
   margin: 0;

}

 .relationship-list--cards {
   gap: 14px;
   padding: 0 18px 18px;
}
 .relationship-list--rows {
   gap: 0;
   padding: 0 22px 10px;
}
 .relationship-card {
   min-width: 0;
   padding: 17px;
   border: 1px solid var(--border);
   border-radius: var(--radius);
   background: var(--surface);
   display: grid;
   grid-template-columns: 44px minmax(0, 1fr) auto;
   align-items: start;
   gap: 14px;

}
 .relationship-card .relationship-avatar {
   flex: none;
   width: 44px;
   height: 44px;
   display: grid;
   place-items: center;
   border-radius: 12px;
   background: var(--brand-soft);
   color: var(--brand);
   font-weight: 800;

}
 .relationship-card .relationship-main {
   min-width: 0;
   display: block;

}
 .relationship-title {
   display: flex;
   align-items: center;
   flex-wrap: wrap;
   gap: 6px;

}
 .relationship-title strong {
   margin-right: 2px;
   color: var(--text-strong);
   font-size: 16px;

}
 .relationship-main > p {
   margin: 7px 0 0;
   color: var(--muted);
   line-height: 1.45;

}
 .contact-details {
   min-width: 0;
   display: grid;
   gap: 6px;
   margin-top: 12px;

}
 .contact-details > span {
   min-width: 0;
   overflow-wrap: anywhere;
   line-height: 1.45;

}
.contact-line {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

 .contact-details form {
   margin: 0;

}
 .relationship-actions {
   display: flex;
   align-items: center;
   justify-content: flex-end;
   flex-wrap: wrap;
   gap: 8px;
   max-width: 250px;

}
 .relationship-actions form {
   margin: 0;

}
 .relationship-actions .small-button {
   white-space: nowrap;

}
 .property-account-summary {
   min-width: 0;
   overflow: hidden;

}
 .property-account-summary .card-header {
   align-items: center;
   padding: 20px 22px;

}
 .property-account-summary .definition-list {
   display: grid;
   grid-template-columns: repeat(3, minmax(0, 1fr));
   gap: 0;
   padding: 0 22px 22px;

}
 .property-account-summary .definition-list > div {
   display: block;
   min-width: 0;
   padding: 16px 18px;
   border-right: 1px solid var(--border);
   border-bottom: 1px solid var(--border);
   background: var(--surface);

}
 .property-account-summary .definition-list > div:nth-child(3n) {
   border-right: 0;

}
 .property-account-summary .definition-list > div:nth-last-child(-n+3) {
   border-bottom: 0;

}
 .property-account-summary .definition-list dt {
   margin-bottom: 6px;
   color: var(--muted);
   font-size: 11px;
   font-weight: 800;
   letter-spacing: .055em;
   text-transform: uppercase;

}
 .property-account-summary .definition-list dd {
   min-width: 0;
   margin: 0;
   color: var(--text-strong);
   font-weight: 650;
   line-height: 1.5;
   overflow-wrap: anywhere;

}
 .property-account-summary .definition-list code {
   white-space: normal;
   overflow-wrap: anywhere;

}
 .property-account-summary .definition-list > div:nth-child(2), .property-account-summary .definition-list > div:nth-child(3), .property-account-summary .definition-list > div:nth-child(5) {
   background: var(--surface-2);

}


 /* Portal property cards: prominent property icon and full-card interaction. */
 .property-card-grid .property-access-card {
   position: relative;
   min-width: 0;
   min-height: 230px;
   display: grid;
   grid-template-rows: auto 1fr;
   gap: 14px;
   padding: 22px;
   color: var(--text);
   text-decoration: none;
   overflow: hidden;
   cursor: pointer;
   transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease, background-color .16s ease;

}
 .property-card-grid .property-access-card:hover {
   transform: translateY(-3px);
   border-color: var(--brand);
   background: color-mix(in srgb, var(--surface) 94%, var(--brand) 6%);
   box-shadow: 0 14px 30px rgba(4, 46, 36, .16);

}
 .property-card-grid .property-access-card:focus-visible {
   outline: 3px solid color-mix(in srgb, var(--brand) 55%, transparent);
   outline-offset: 3px;
   border-color: var(--brand);

}
 .property-card-house {
   width: 92px;
   height: 92px;
   display: grid;
   place-items: center;
   border-radius: 22px;
   background: var(--brand-soft);
   color: var(--brand);
   font-size: 76px;
   font-weight: 800;
   line-height: 1;
   font-family: Georgia, "Times New Roman", serif;
   box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--brand) 16%, transparent);

}
 .property-card-content {
   min-width: 0;
   display: flex;
   flex-direction: column;
   align-items: flex-start;

}
 .property-card-content .property-number {
   display: inline-flex;
   align-items: center;
   min-height: 28px;
   padding: 4px 10px;
   border-radius: 999px;
   background: var(--brand-soft);
   color: var(--brand);
   font-size: 13px;
   font-weight: 800;
   letter-spacing: .02em;

}
 .property-card-content h3 {
   margin: 12px 0 6px;
   color: var(--text-strong);
   font-size: 21px;
   line-height: 1.25;
   overflow-wrap: anywhere;

}
 .property-card-content p {
   margin: 0 0 8px;
   color: var(--muted);
   line-height: 1.45;

}
 .property-card-content small {
   color: var(--text);
   font-weight: 650;

}
 .property-card-action {
   display: inline-flex;
   align-items: center;
   gap: 7px;
   margin-top: auto;
   padding-top: 18px;
   color: var(--brand);
   font-weight: 800;

}
 .property-card-action span {
   font-size: 24px;
   line-height: .8;
   transition: transform .16s ease;

}
 .property-access-card:hover .property-card-action span, .property-access-card:focus-visible .property-card-action span {
   transform: translateX(4px);

}
 @media (max-width: 720px) {
   .property-card-grid .property-access-card {
     min-height: 190px;
     padding: 18px;

  }
   .property-card-house {
     width: 76px;
     height: 76px;
     border-radius: 18px;
     font-size: 62px;

  }

}
 /* My statement property selector. Reuses the large portal property-card language. */
 .statement-card-grid {
   margin-top: 18px;

}
 .property-card-grid .statement-property-card {
   min-height: 420px ;

}
 .statement-card-heading {
   width: 100%;
   display: flex;
   align-items: center;
   justify-content: space-between;
   gap: 10px;

}
 .statement-card-balance {
   width: 100%;
   margin: 15px 0 11px;
   padding: 13px 14px;
   border: 1px solid var(--border);
   border-radius: 10px;
   background: var(--surface-2);

}
 .statement-card-balance span {
   display: block;
   color: var(--muted);
   font-size: 12px;

}
 .statement-card-balance strong {
   display: block;
   margin-top: 3px;
   color: var(--text-strong);
   font-size: 23px;
   line-height: 1.2;

}
 .statement-card-details {
   width: 100%;
   display: grid;
   gap: 8px;
   margin: 0;

}
 .statement-card-details > div {
   display: grid;
   grid-template-columns: minmax(105px,.85fr) minmax(0,1.4fr);
   gap: 10px;
   padding-top: 8px;
   border-top: 1px solid var(--border);

}
 .statement-card-details dt {
   color: var(--muted);
   font-size: 12px;

}
 .statement-card-details dd {
   margin: 0;
   color: var(--text);
   font-size: 12px;
   font-weight: 650;
   text-align: right;
   overflow-wrap: anywhere;

}
 .statement-empty-state {
   grid-column: 1 / -1;

}
 @media (max-width: 720px) {
   .property-card-grid .statement-property-card {
     min-height: 380px ;

  }
   .statement-card-details > div {
     grid-template-columns: 1fr;
     gap: 3px;

  }
   .statement-card-details dd {
     text-align: left;

  }

}
 /* Property detail: integrated owner/contact rows */
 .property-relationship-row {
   min-width:0;
   display:grid;
   grid-template-columns:44px minmax(0,1fr) auto;
   align-items:start;
   gap:14px;
   padding:18px 0;
   border-bottom:1px solid var(--border);
   background:transparent
}
 .property-relationship-row:last-child {
   border-bottom:0
}
 .property-relationship-row .relationship-avatar {
   flex:none
}
 .property-relationship-row .relationship-main {
   min-width:0;
   display:block
}
 .property-relationship-row .relationship-actions {
   align-self:center
}
 @media(max-width:700px) {
   .relationship-list--rows, .relationship-list--cards {
     padding-inline:17px
  }
   .property-relationship-row {
     grid-template-columns:44px minmax(0,1fr)
  }
   .property-relationship-row .relationship-actions {
     grid-column:1/-1;
     justify-content:flex-start;
     max-width:none;
     padding-left:58px
  }

}
 @media(max-width:1000px) {
   .property-account-summary .definition-list {
     grid-template-columns:repeat(2,minmax(0,1fr))
  }
   .property-account-summary .definition-list>div:nth-child(3n) {
     border-right:1px solid var(--border)
  }
   .property-account-summary .definition-list>div:nth-child(2n) {
     border-right:0
  }
   .property-account-summary .definition-list>div:nth-last-child(-n+3) {
     border-bottom:1px solid var(--border)
  }
   .property-account-summary .definition-list>div:nth-last-child(-n+2) {
     border-bottom:0
  }

}
 @media(max-width:700px) {
   .property-account-summary .card-header {
     padding:17px
  }
   .property-account-summary .definition-list {
     grid-template-columns:1fr;
     padding:0 17px 17px
  }
   .property-account-summary .definition-list>div:nth-child(n) {
     border-right:0;
     border-bottom:1px solid var(--border);
     padding:14px 0;
     background:transparent
  }
   .property-account-summary .definition-list>div:nth-last-child(1) {
     border-bottom:0
  }

}
 /* Property statement controls and section spacing */
 .statement-actions {
   display: flex;
   align-items: flex-end;
   justify-content: flex-end;
   gap: 10px;
   flex-wrap: wrap;

}
 .statement-date-form {
   display: flex;
   align-items: flex-end;
   gap: 10px;
   margin: 0;

}
 .statement-date-form label {
   display: grid;
   gap: 7px;
   margin: 0;
   color: var(--text);
   font-size: 13px;
   font-weight: 700;

}
 .statement-date-form .native-temporal-control, .statement-date-form .button, .statement-actions .export-dropdown > summary {
   height: 46px;
   min-height: 46px;
   box-sizing: border-box;

}
 .statement-date-form .native-temporal-control {
   min-width: 170px;

}
 .statement-actions .export-dropdown {
   align-self: flex-end;

}
 .statement-actions .export-dropdown > summary {
   display: inline-flex;
   align-items: center;
   justify-content: center;
   min-width: 104px;

}
 .statement-current-card + .statement-legacy-card {
   margin-top: 20px;

}
 @media (max-width: 760px) {
   .statement-actions, .statement-date-form {
     width: 100%;
     align-items: stretch;

  }
   .statement-date-form {
     display: grid;
     grid-template-columns: minmax(0, 1fr);

  }
   .statement-date-form label {
     grid-column: auto;

  }
   .statement-date-form .native-temporal-control {
     min-width: 0;

  }
   .statement-date-form .native-temporal-control, .statement-date-form .button, .statement-actions .export-dropdown, .statement-actions .export-dropdown > summary {
     width: 100%;

  }
   .statement-current-card + .statement-legacy-card {
     margin-top: 16px;

  }

}


/* Properties register toolbar and domain tables. */
.properties-page-toolbar {
  align-items: flex-start;
}

.properties-page-toolbar .property-filters {
  flex: 1 1 auto;
  min-width: 0;
  margin-bottom: 0;
}

.property-add-button {
  flex: 0 0 auto;
  white-space: nowrap;
}

.properties-page-toolbar .property-filters .search-box {
  grid-column: span 2;
}


@media (max-width: 760px) {
  .properties-page-toolbar {
    width: 100%;
  }

  .properties-page-toolbar .property-filters,
  .statement-date-form {
    grid-template-columns: minmax(0, 1fr);
  }

  .properties-page-toolbar .property-filters .search-box,
  .properties-page-toolbar .property-filters > *,
  .properties-page-toolbar > .property-add-button {
    grid-column: auto;
    width: 100%;
    min-width: 0;
    max-width: 100%;
  }

  .property-add-button {
    justify-content: center;
  }
}
/* ===== END pages/properties.css ===== */

/* ===== BEGIN pages/billing.css ===== */
/*
 * ARBS stylesheet: pages/billing.css
 * Purpose: Billing accounts, charges, penalties and statement presentation.
 * Architecture: Page layer; billing-only selectors.
 */

 .billing-guidance-grid {
   display:grid;
   grid-template-columns:repeat(2,minmax(0,1fr));
   gap:1rem;
   margin-bottom:1.25rem
}
 .billing-guidance-item {
   display:grid;
   grid-template-columns:56px minmax(0,1fr);
   gap:1rem;
   align-items:start;
   padding:1.25rem 1.4rem;
   background:var(--surface);
   border:1px solid var(--border);
   border-radius:16px;
   box-shadow:var(--shadow-sm)
}
 .billing-guidance-icon {
   display:grid;
   place-items:center;
   width:56px;
   height:56px;
   border-radius:16px;
   background:color-mix(in srgb,var(--brand) 14%,transparent);
   color:var(--brand);
   font-size:1.6rem
}
 .billing-guidance-icon--warning {
   background:rgba(180,83,9,.12);
   color:#b45309
}
 .billing-guidance-copy {
   display:grid;
   gap:.45rem
}
 .billing-guidance-copy strong {
   display:block;
   color:var(--text-strong);
   font-size:1.02rem
}
 .billing-guidance-copy p {
   margin:0;
   color:var(--muted);
   line-height:1.6
}

 /* Billing configuration summary cards */
 .billing-status-section {
   display:grid;
   gap:1rem
}
 .billing-status-heading {
   display:flex;
   align-items:flex-end;
   justify-content:space-between;
   gap:1rem;
   padding:0 .1rem
}
 .billing-status-heading h3 {
   margin:.2rem 0 .25rem;
   color:var(--text-strong);
   font-size:1.18rem
}
 .billing-status-heading p {
   max-width:760px;
   margin:0;
   color:var(--muted);
   line-height:1.5
}
 .billing-status-grid {
   display:grid;
   grid-template-columns:repeat(4,minmax(0,1fr));
   gap:1rem
}
 .billing-status-card {
   display:flex;
   flex-direction:column;
   min-width:0;
   min-height:178px;
   padding:1.15rem 1.2rem;
   border:1px solid var(--border);
   border-radius:16px;
   background:var(--surface);
   box-shadow:var(--shadow-sm)
}
 .billing-status-card__topline {
   display:flex;
   align-items:center;
   gap:.65rem;
   min-height:34px
}
 .billing-status-icon {
   display:grid;
   place-items:center;
   flex:0 0 32px;
   width:32px;
   height:32px;
   border-radius:10px;
   background:color-mix(in srgb,var(--brand) 13%,transparent);
   color:var(--brand);
   font-size:1rem;
   font-weight:900
}
 .billing-status-icon--warning {
   background:rgba(180,83,9,.12);
   color:#b45309
}
 .billing-status-label {
   color:var(--muted);
   font-size:.76rem;
   font-weight:800;
   letter-spacing:.06em;
   line-height:1.3;
   text-transform:uppercase
}
 .billing-status-value {
   margin:.9rem 0 auto;
   color:var(--text-strong);
   font-size:2rem;
   font-weight:850;
   letter-spacing:-.04em;
   line-height:1
}
 .billing-status-value--text {
   font-size:1.55rem;
   letter-spacing:-.025em
}
 .billing-status-meta {
   display:grid;
   gap:.2rem;
   padding-top:.9rem;
   border-top:1px solid var(--border)
}
 .billing-status-meta__label {
   color:var(--muted-2);
   font-size:.68rem;
   font-weight:800;
   letter-spacing:.07em;
   text-transform:uppercase
}
 .billing-status-meta strong {
   color:var(--text);
   font-size:.83rem;
   line-height:1.4
}
 @media(max-width:1050px) {
   .billing-status-grid {
     grid-template-columns:repeat(2,minmax(0,1fr))
  }

}
 @media(max-width:620px) {
   .billing-status-grid {
     grid-template-columns:1fr
  }
   .billing-status-card {
     min-height:0
  }
   .billing-status-value {
     margin-bottom:1rem
  }

}
 /* Penalty policy review and asynchronous assessment flow */
 .penalty-policy-card {
   overflow:hidden
}
 .penalty-policy-card__heading {
   align-items:center
}
 .penalty-policy-action {
   display:flex;
   align-items:center;
   justify-content:space-between;
   gap:1rem;
   padding:1rem 1.4rem;
   border-bottom:1px solid var(--border);
   background:var(--surface-2)
}
 .penalty-policy-action>div {
   min-width:0
}
 .penalty-policy-action strong {
   display:block;
   color:var(--text-strong)
}
 .penalty-policy-action p {
   max-width:560px;
   margin:.3rem 0 0;
   color:var(--muted);
   font-size:.86rem;
   line-height:1.5
}
 .penalty-review-button {
   flex:0 0 auto;
   min-width:172px;
   white-space:nowrap
}
 .penalty-task-status {
   display:grid;
   grid-template-columns:44px minmax(0,1fr);
   gap:.9rem;
   align-items:center;
   margin-bottom:1.25rem;
   padding:1rem 1.15rem;
   border:1px solid color-mix(in srgb,var(--brand) 30%,var(--border));
   border-radius:14px;
   background:var(--brand-soft);
   box-shadow:var(--shadow-sm)
}
 .penalty-task-status__icon {
   display:grid;
   place-items:center;
   width:44px;
   height:44px;
   border-radius:12px;
   background:var(--brand);
   color:#fff;
   font-size:1.2rem;
   font-weight:900
}
 .penalty-task-status strong {
   display:block;
   color:var(--text-strong)
}
 .penalty-task-status p {
   margin:.25rem 0 0;
   color:var(--text);
   line-height:1.45
}
 .penalty-task-status.is-complete {
   border-color:rgba(21,128,61,.3);
   background:rgba(21,128,61,.08)
}
 .penalty-task-status.is-failed {
   border-color:rgba(185,28,28,.3);
   background:rgba(185,28,28,.08)
}
 .penalty-task-status.is-failed .penalty-task-status__icon {
   background:#b91c1c
}
 .penalty-review-summary {
   display:grid;
   grid-template-columns:repeat(4,minmax(0,1fr));
   gap:1rem
}
 .penalty-review-summary article {
   display:flex;
   flex-direction:column;
   min-width:0;
   min-height:154px;
   padding:1.1rem 1.2rem;
   border:1px solid var(--border);
   border-radius:15px;
   background:var(--surface);
   box-shadow:var(--shadow-sm)
}
 .penalty-review-summary span {
   color:var(--muted);
   font-size:.75rem;
   font-weight:800;
   letter-spacing:.06em;
   text-transform:uppercase
}
 .penalty-review-summary strong {
   margin:.65rem 0;
   color:var(--text-strong);
   font-size:1.65rem;
   line-height:1.15;
   overflow-wrap:anywhere
}
 .penalty-review-summary small {
   margin-top:auto;
   color:var(--muted);
   line-height:1.45
}
 .penalty-review-layout {
   grid-template-columns:minmax(0,1.35fr) minmax(320px,.65fr)
}
 .penalty-review-policy {
   align-items:center
}
 .penalty-review-policy__meta {
   flex:0 0 auto;
   text-align:right
}
 .penalty-review-policy__meta strong,.penalty-review-policy__meta span {
   display:block
}
 .penalty-review-policy__meta span {
   margin-top:.2rem
}
 .penalty-confirm-card {
   align-self:start
}
 .penalty-confirm-note {
   padding:1rem;
   border:1px solid color-mix(in srgb,var(--brand) 22%,var(--border));
   border-radius:12px;
   background:var(--brand-soft)
}
 .penalty-confirm-note strong {
   display:block;
   color:var(--text-strong)
}
 .penalty-confirm-note p {
   margin:.4rem 0 0;
   color:var(--text);
   line-height:1.55
}
 .penalty-confirm-form {
   display:grid;
   gap:.7rem;
   margin-top:1rem
}
 .penalty-confirm-form .button {
   width:100%;
   white-space:nowrap
}
 @media(max-width:1000px) {
   .penalty-review-summary {
     grid-template-columns:repeat(2,minmax(0,1fr))
  }
   .penalty-review-layout {
     grid-template-columns:1fr
  }

}
 @media(max-width:700px) {
   .penalty-policy-action {
     align-items:stretch;
     flex-direction:column
  }
   .penalty-review-button {
     width:100%;
     min-width:0
  }
   .penalty-review-summary {
     grid-template-columns:1fr
  }
   .penalty-review-summary article {
     min-height:0
  }
   .penalty-review-policy {
     align-items:flex-start
  }
   .penalty-review-policy__meta {
     text-align:left
  }

}
 /* Payment integrations */
 .integration-page-header {
   display:flex;
   align-items:flex-start;
   justify-content:space-between;
   gap:1.5rem;
   margin-bottom:1.25rem
}
 .integration-page-heading {
   max-width:760px
}
 .integration-page-heading h2 {
   margin:.2rem 0 .45rem;
   color:var(--text-strong);
   font-size:clamp(1.55rem,2vw,2rem);
   letter-spacing:-.025em
}
 .integration-page-heading p {
   margin:0;
   color:var(--muted);
   line-height:1.6
}
 .integration-guidance {
   display:grid;
   grid-template-columns:52px minmax(0,1fr);
   gap:1rem;
   align-items:start;
   margin-bottom:1.25rem;
   padding:1.15rem 1.25rem;
   border:1px solid color-mix(in srgb,var(--brand) 24%,var(--border));
   border-radius:16px;
   background:color-mix(in srgb,var(--brand) 7%,var(--surface));
   box-shadow:var(--shadow-sm)
}
 .integration-guidance__icon {
   display:grid;
   place-items:center;
   width:52px;
   height:52px;
   border-radius:14px;
   background:var(--brand);
   color:#fff
}
 .integration-guidance__icon svg {
   width:26px;
   height:26px
}
 .integration-guidance strong {
   display:block;
   margin:.05rem 0 .3rem;
   color:var(--text-strong);
   font-size:1rem
}
 .integration-guidance p {
   margin:0;
   color:var(--muted);
   line-height:1.55
}
 .integration-card-grid {
   display:grid;
   grid-template-columns:repeat(2,minmax(0,1fr));
   gap:1.25rem;
   align-items:stretch
}
 .integration-card {
   display:flex;
   flex-direction:column;
   min-width:0;
   overflow:hidden;
   border:1px solid var(--border);
   border-radius:18px;
   background:var(--surface);
   box-shadow:var(--shadow-sm)
}
 .integration-card__header {
   display:flex;
   align-items:flex-start;
   justify-content:space-between;
   gap:1rem;
   padding:1.35rem 1.4rem;
   border-bottom:1px solid var(--border);
   background:linear-gradient(180deg,color-mix(in srgb,var(--brand) 5%,var(--surface)),var(--surface))
}
 .integration-card__identity {
   display:grid;
   grid-template-columns:52px minmax(0,1fr);
   gap:1rem;
   min-width:0
}
 .integration-card__icon {
   display:grid;
   place-items:center;
   width:52px;
   height:52px;
   border-radius:15px;
   background:var(--brand-soft);
   color:var(--brand)
}
 .integration-card__icon svg {
   width:27px;
   height:27px
}
 .integration-card__eyebrow {
   display:block;
   margin-bottom:.2rem;
   color:var(--brand);
   font-size:.7rem;
   font-weight:800;
   letter-spacing:.09em;
   text-transform:uppercase
}
 .integration-card__header h3 {
   margin:0;
   color:var(--text-strong);
   font-size:1.2rem
}
 .integration-card__header p {
   margin:.35rem 0 0;
   color:var(--muted);
   font-size:.88rem;
   line-height:1.5
}
 .integration-status {
   display:inline-flex;
   align-items:center;
   gap:.45rem;
   flex:0 0 auto;
   min-height:32px;
   padding:.4rem .65rem;
   border:1px solid var(--border);
   border-radius:999px;
   background:var(--surface-2);
   color:var(--muted);
   font-size:.75rem;
   font-weight:800;
   white-space:nowrap
}
 .integration-status>span {
   width:8px;
   height:8px;
   border-radius:50%;
   background:currentColor
}
 .integration-status.is-enabled {
   border-color:var(--success-border);
   background:var(--success-soft);
   color:var(--success)
}
 .integration-status.is-disabled {
   border-color:var(--warning-border);
   background:var(--warning-soft);
   color:var(--warning)
}
 .integration-card__body {
   display:grid;
   gap:1rem;
   flex:1;
   padding:1.35rem 1.4rem
}
 .integration-detail-grid {
   display:grid;
   grid-template-columns:repeat(2,minmax(0,1fr));
   gap:.85rem;
   margin:0
}
 .integration-detail-grid>div {
   min-width:0;
   padding:1rem;
   border:1px solid var(--border);
   border-radius:13px;
   background:var(--surface-2)
}
 .integration-detail-grid dt {
   margin:0 0 .35rem;
   color:var(--muted);
   font-size:.7rem;
   font-weight:800;
   letter-spacing:.065em;
   text-transform:uppercase
}
 .integration-detail-grid dd {
   margin:0;
   color:var(--text-strong);
   font-weight:750;
   line-height:1.4;
   overflow-wrap:anywhere
}
 .integration-endpoint {
   display:grid;
   grid-template-columns:42px minmax(0,1fr);
   gap:.85rem;
   align-items:start;
   padding:1rem;
   border:1px solid var(--border);
   border-radius:13px;
   background:var(--surface)
}
 .integration-endpoint__icon {
   display:grid;
   place-items:center;
   width:42px;
   height:42px;
   border-radius:11px;
   background:var(--brand-soft);
   color:var(--brand)
}
 .integration-endpoint__icon svg {
   width:21px;
   height:21px
}
 .integration-endpoint span {
   display:block;
   margin-bottom:.3rem;
   color:var(--muted);
   font-size:.72rem;
   font-weight:800;
   letter-spacing:.06em;
   text-transform:uppercase
}
 .integration-endpoint code {
   display:block;
   padding:.55rem .65rem;
   border-radius:8px;
   background:var(--surface-3);
   color:var(--text-strong);
   font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;
   font-size:.78rem;
   line-height:1.45;
   overflow-wrap:anywhere;
   white-space:normal
}
 .integration-empty-state {
   display:grid;
   grid-template-columns:44px minmax(0,1fr);
   gap:.9rem;
   align-items:start;
   padding:1rem;
   border:1px dashed var(--warning-border);
   border-radius:13px;
   background:var(--warning-soft)
}
 .integration-empty-state__icon {
   display:grid;
   place-items:center;
   width:44px;
   height:44px;
   border-radius:12px;
   background:var(--warning);
   color:#fff;
   font-weight:900
}
 .integration-empty-state strong {
   display:block;
   color:var(--text-strong)
}
 .integration-empty-state p {
   margin:.3rem 0 0;
   color:var(--muted);
   line-height:1.5
}
 .integration-card__footer {
   display:flex;
   align-items:center;
   justify-content:space-between;
   gap:1rem;
   margin-top:auto;
   padding:1.15rem 1.4rem;
   border-top:1px solid var(--border);
   background:var(--surface-2)
}
 .integration-card__footer p {
   max-width:360px;
   margin:0;
   color:var(--muted);
   font-size:.78rem;
   line-height:1.45
}
 .integration-card__footer .button {
   flex:0 0 auto;
   white-space:nowrap
}
 .integration-processing-note {
   display:grid;
   grid-template-columns:48px minmax(0,1fr);
   gap:1rem;
   align-items:start;
   margin-top:1.25rem;
   padding:1.2rem 1.3rem;
   border:1px solid var(--warning-border);
   border-radius:16px;
   background:var(--warning-soft)
}
 .integration-processing-note__icon {
   display:grid;
   place-items:center;
   width:48px;
   height:48px;
   border-radius:13px;
   background:var(--warning);
   color:#fff
}
 .integration-processing-note__icon svg {
   width:24px;
   height:24px
}
 .integration-processing-note strong {
   display:block;
   color:var(--warning);
   font-size:1rem
}
 .integration-processing-note p {
   margin:.35rem 0 0;
   color:var(--text);
   line-height:1.6
}
 @media(max-width:1050px) {
   .integration-card-grid {
     grid-template-columns:1fr
  }
   .integration-card__footer p {
     max-width:none
  }

}
 @media(max-width:700px) {
   .integration-page-header {
     flex-direction:column
  }
   .integration-page-header>.button {
     width:100%
  }
   .integration-guidance {
     grid-template-columns:44px minmax(0,1fr);
     padding:1rem
  }
   .integration-guidance__icon {
     width:44px;
     height:44px;
     border-radius:12px
  }
   .integration-card__header {
     flex-direction:column;
     padding:1.1rem
  }
   .integration-card__identity {
     grid-template-columns:46px minmax(0,1fr)
  }
   .integration-card__icon {
     width:46px;
     height:46px
  }
   .integration-status {
     align-self:flex-start
  }
   .integration-card__body {
     padding:1.1rem
  }
   .integration-detail-grid {
     grid-template-columns:1fr
  }
   .integration-card__footer {
     align-items:stretch;
     flex-direction:column;
     padding:1.1rem
  }
   .integration-card__footer .button {
     width:100%
  }
   .integration-processing-note {
     grid-template-columns:42px minmax(0,1fr);
     padding:1rem
  }
   .integration-processing-note__icon {
     width:42px;
     height:42px
  }

}

/* Billing and integration phone layout. */
@media (max-width: 760px) {
  .billing-guidance-grid,
  .billing-status-grid,
  .penalty-review-summary,
  .penalty-review-layout,
  .integration-card-grid,
  .integration-detail-grid { grid-template-columns: minmax(0, 1fr); }
  .billing-guidance-grid > *,
  .billing-status-grid > *,
  .penalty-review-summary > *,
  .penalty-review-layout > *,
  .integration-card-grid > *,
  .integration-detail-grid > * { min-width: 0; }
}

/* Custom invoice workflow */
.custom-invoice-page {
  width: min(1180px, 100%);
  margin: 0 auto;
  padding-bottom: 2.5rem;
}

.custom-invoice-header {
  align-items: flex-start;
  margin-bottom: 1.35rem;
}

.custom-invoice-header > div:first-child {
  max-width: 780px;
}

.custom-invoice-header h2 {
  margin-bottom: .35rem;
}

.custom-invoice-header p {
  max-width: 720px;
  margin: 0;
  line-height: 1.6;
}

.custom-invoice-progress {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 0 0 1.4rem;
  padding: .9rem 1rem;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.custom-invoice-progress::before {
  position: absolute;
  top: 50%;
  left: calc(16.666% + 24px);
  right: calc(16.666% + 24px);
  height: 1px;
  background: var(--border);
  content: "";
}

.custom-invoice-progress > div {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: .6rem;
  min-width: 0;
  color: var(--muted);
}

.custom-invoice-progress span {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  flex: 0 0 32px;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: var(--surface);
  color: var(--muted);
  font-size: .76rem;
  font-weight: 850;
}

.custom-invoice-progress strong {
  padding: .2rem .35rem;
  background: var(--surface);
  color: inherit;
  font-size: .82rem;
  font-weight: 800;
  white-space: nowrap;
}

.custom-invoice-progress .is-current {
  color: var(--text-strong);
}

.custom-invoice-progress .is-current span {
  border-color: var(--brand);
  background: var(--brand);
  color: #fff;
}

.custom-invoice-progress .is-complete {
  color: var(--text-strong);
}

.custom-invoice-progress .is-complete span {
  border-color: var(--success);
  background: var(--success);
  color: #fff;
}

.custom-invoice-errors {
  margin-bottom: 1.2rem;
}

.custom-invoice-errors ul {
  margin: .55rem 0 0;
  padding-left: 1.2rem;
}

.custom-invoice-form {
  display: grid;
  gap: 1.15rem;
}

.custom-invoice-section {
  overflow: visible;
  border-radius: 14px;
}

.custom-invoice-section .staff-card-heading {
  padding: 1.2rem 1.35rem 1.05rem;
  border-bottom: 1px solid var(--border);
}

.custom-invoice-section .staff-card-heading > div {
  max-width: 790px;
}

.custom-invoice-section .staff-card-heading h3 {
  margin: .2rem 0 .3rem;
  font-size: 1rem;
}

.custom-invoice-section .staff-card-heading p {
  margin: 0;
  color: var(--muted);
  font-size: .79rem;
  line-height: 1.55;
}

.custom-invoice-section .staff-card-body {
  padding: 1.25rem 1.35rem 1.35rem;
}

.custom-invoice-grid {
  display: grid;
  gap: 1.15rem 1.2rem;
}

.custom-invoice-grid--identity {
  grid-template-columns: minmax(0, 1.7fr) minmax(220px, .8fr);
}

.custom-invoice-grid--identity .custom-invoice-title-field {
  min-width: 0;
}

.custom-invoice-grid--identity .field-group:nth-child(3) {
  grid-column: 1 / -1;
  max-width: 420px;
}

.custom-invoice-grid--financial {
  grid-template-columns: minmax(220px, 1.15fr) repeat(2, minmax(180px, 1fr));
}

.custom-invoice-grid--scope {
  grid-template-columns: minmax(260px, .8fr) minmax(0, 1.4fr);
}

.custom-invoice-grid .span-full {
  grid-column: 1 / -1;
}

.custom-invoice-grid .field-group {
  min-width: 0;
  margin: 0;
}

.custom-invoice-grid .field-group label {
  display: block;
  margin: 0 0 .45rem;
  color: var(--text-strong);
  font-size: .79rem;
  font-weight: 780;
}

.custom-invoice-grid .field-group input,
.custom-invoice-grid .field-group select,
.custom-invoice-grid .field-group textarea {
  width: 100%;
  max-width: 100%;
  min-height: 48px;
  padding: .76rem .9rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  color: var(--text);
  font: inherit;
  line-height: 1.35;
}

.custom-invoice-grid .field-group textarea {
  min-height: 180px;
  resize: vertical;
  line-height: 1.6;
}

.custom-invoice-grid .field-group input:focus,
.custom-invoice-grid .field-group select:focus,
.custom-invoice-grid .field-group textarea:focus {
  outline: 0;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 14%, transparent);
}

.custom-invoice-grid .help-text {
  display: block;
  margin-top: .4rem;
  color: var(--muted);
  font-size: .71rem;
  line-height: 1.45;
}

.custom-invoice-affix-field {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: stretch;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
}

.custom-invoice-affix-field:focus-within {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 14%, transparent);
}

.custom-invoice-affix-field > span {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 46px;
  padding: 0 .8rem;
  border-right: 1px solid var(--border);
  background: var(--surface-2);
  color: var(--text-strong);
  font-size: .77rem;
  font-weight: 800;
}

.custom-invoice-affix-field--money > span {
  min-width: 68px;
}

.custom-invoice-affix-field input {
  width: 100%;
  min-width: 0;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.custom-invoice-affix-field input:focus {
  box-shadow: none;
}

#custom-selected-plots-panel.is-disabled {
  opacity: .52;
}

#custom-selected-plots-panel.is-disabled input {
  cursor: not-allowed;
  background: var(--surface-2);
}

.custom-invoice-notifications {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: .9rem;
}

.custom-invoice-notification {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  align-items: start;
  gap: .75rem;
  min-height: 100px;
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: 11px;
  background: var(--surface-2);
  cursor: pointer;
  transition: border-color .15s ease, background .15s ease, box-shadow .15s ease;
}

.custom-invoice-notification:hover {
  border-color: color-mix(in srgb, var(--brand) 36%, var(--border));
  background: var(--surface);
}

.custom-invoice-notification input {
  width: 18px;
  height: 18px;
  margin: .12rem 0 0;
  accent-color: var(--brand);
}

.custom-invoice-notification > span {
  display: grid;
  gap: .28rem;
  min-width: 0;
}

.custom-invoice-notification strong {
  display: block;
  color: var(--text-strong);
  font-size: .82rem;
  line-height: 1.35;
}

.custom-invoice-notification small {
  display: block;
  color: var(--muted);
  font-size: .72rem;
  line-height: 1.5;
}

.custom-invoice-notification:has(input:checked) {
  border-color: color-mix(in srgb, var(--brand) 48%, var(--border));
  background: color-mix(in srgb, var(--brand) 5%, var(--surface));
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--brand) 10%, transparent);
}

.custom-invoice-notification-note {
  margin: 0 1.35rem 1.3rem;
  padding: .78rem .9rem;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: var(--surface-2);
  color: var(--muted);
  font-size: .72rem;
  line-height: 1.5;
}

.custom-invoice-actions {
  margin-top: .1rem;
}

.custom-invoice-preview-summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(470px, .9fr);
  align-items: center;
  gap: 1.3rem;
  margin-bottom: 1rem;
  padding: 1.25rem 1.35rem;
}

.custom-invoice-preview-title {
  min-width: 0;
}

.custom-invoice-preview-title h3 {
  margin: .18rem 0 .28rem;
  color: var(--text-strong);
  font-size: 1.2rem;
}

.custom-invoice-preview-title p {
  margin: 0;
  color: var(--muted);
  font-size: .77rem;
}

.custom-invoice-preview-totals {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: .7rem;
}

.custom-invoice-preview-totals > div {
  min-width: 0;
  padding: .8rem .85rem;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: var(--surface-2);
}

.custom-invoice-preview-totals span {
  display: block;
  margin-bottom: .3rem;
  color: var(--muted);
  font-size: .64rem;
  font-weight: 800;
  letter-spacing: .05em;
  text-transform: uppercase;
}

.custom-invoice-preview-totals strong {
  display: block;
  color: var(--text-strong);
  font-size: .88rem;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.custom-invoice-preview-totals .is-primary {
  border-color: color-mix(in srgb, var(--brand) 34%, var(--border));
  background: color-mix(in srgb, var(--brand) 5%, var(--surface));
}

.custom-invoice-preview-totals .is-primary strong {
  color: var(--brand);
}

.custom-invoice-preview-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 1rem;
  align-items: start;
}

.custom-invoice-preview-main {
  display: grid;
  gap: 1rem;
  min-width: 0;
}

.custom-invoice-detail-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 0;
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
}

.custom-invoice-detail-list > div {
  min-width: 0;
  padding: .9rem 1rem;
  border-bottom: 1px solid var(--border);
}

.custom-invoice-detail-list > div:nth-child(odd) {
  border-right: 1px solid var(--border);
}

.custom-invoice-detail-list > div:nth-last-child(-n+2) {
  border-bottom: 0;
}

.custom-invoice-detail-list dt {
  margin: 0 0 .28rem;
  color: var(--muted);
  font-size: .65rem;
  font-weight: 800;
  letter-spacing: .05em;
  text-transform: uppercase;
}

.custom-invoice-detail-list dd {
  margin: 0;
  color: var(--text-strong);
  font-size: .81rem;
  font-weight: 740;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.custom-invoice-number-pattern {
  display: grid;
  gap: .42rem;
  margin-top: 1rem;
  padding: .9rem 1rem;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: var(--surface-2);
}

.custom-invoice-number-pattern span,
.custom-invoice-description-preview > span {
  color: var(--muted);
  font-size: .65rem;
  font-weight: 800;
  letter-spacing: .05em;
  text-transform: uppercase;
}

.custom-invoice-number-pattern code {
  color: var(--text-strong);
  font-size: .78rem;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.custom-invoice-description-preview {
  display: grid;
  gap: .55rem;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
}

.custom-invoice-description-preview > div {
  color: var(--text);
  font-size: .8rem;
  line-height: 1.7;
  overflow-wrap: anywhere;
}

.custom-invoice-recipient-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.custom-invoice-recipient-table {
  max-height: 560px;
}

.custom-invoice-recipient-table table {
  margin: 0;
}

.custom-invoice-recipient-table th,
.custom-invoice-recipient-table td {
  padding: .78rem .95rem;
}

.custom-invoice-confirm-panel {
  min-width: 0;
}

.custom-invoice-confirm-card {
  position: sticky;
  top: 1rem;
  overflow: hidden;
}

.custom-invoice-confirm-body {
  display: grid;
  gap: 1rem;
}

.custom-invoice-delivery-status {
  display: grid;
  gap: .65rem;
}

.custom-invoice-delivery-status > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: .75rem .8rem;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: var(--surface-2);
}

.custom-invoice-delivery-status span {
  color: var(--muted);
  font-size: .72rem;
}

.custom-invoice-delivery-status strong {
  color: var(--text-strong);
  font-size: .76rem;
}

.custom-invoice-background-note {
  padding: .9rem;
  border-left: 3px solid var(--brand);
  border-radius: 8px;
  background: color-mix(in srgb, var(--brand) 5%, var(--surface));
}

.custom-invoice-background-note strong {
  display: block;
  color: var(--text-strong);
  font-size: .76rem;
}

.custom-invoice-background-note p {
  margin: .28rem 0 0;
  color: var(--muted);
  font-size: .71rem;
  line-height: 1.5;
}

.custom-invoice-preview-actions {
  display: grid;
  gap: .65rem;
}

.custom-invoice-preview-actions form,
.custom-invoice-preview-actions .button {
  width: 100%;
  margin: 0;
}

.custom-invoice-preview-actions .button {
  justify-content: center;
}

@media (max-width: 1000px) {
  .custom-invoice-grid--identity,
  .custom-invoice-grid--financial,
  .custom-invoice-grid--scope {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .custom-invoice-grid--identity .custom-invoice-title-field,
  .custom-invoice-grid--identity .field-group:nth-child(3) {
    grid-column: 1 / -1;
    max-width: none;
  }

  .custom-invoice-preview-summary {
    grid-template-columns: 1fr;
  }

  .custom-invoice-preview-layout {
    grid-template-columns: 1fr;
  }

  .custom-invoice-confirm-card {
    position: static;
  }
}

@media (max-width: 760px) {
  .custom-invoice-page {
    padding-bottom: 1.5rem;
  }

  .custom-invoice-header {
    gap: .9rem;
  }

  .custom-invoice-progress {
    padding: .75rem .65rem;
  }

  .custom-invoice-progress::before {
    left: calc(16.666% + 18px);
    right: calc(16.666% + 18px);
  }

  .custom-invoice-progress > div {
    gap: .35rem;
  }

  .custom-invoice-progress span {
    width: 28px;
    height: 28px;
    flex-basis: 28px;
  }

  .custom-invoice-progress strong {
    font-size: .72rem;
  }

  .custom-invoice-grid--identity,
  .custom-invoice-grid--financial,
  .custom-invoice-grid--scope,
  .custom-invoice-notifications,
  .custom-invoice-detail-list,
  .custom-invoice-preview-totals {
    grid-template-columns: 1fr;
  }

  .custom-invoice-grid .span-full,
  .custom-invoice-grid--identity .custom-invoice-title-field,
  .custom-invoice-grid--identity .field-group:nth-child(3) {
    grid-column: auto;
  }

  .custom-invoice-section .staff-card-heading,
  .custom-invoice-section .staff-card-body {
    padding: 1rem;
  }

  .custom-invoice-notification-note {
    margin: 0 1rem 1rem;
  }

  .custom-invoice-preview-summary {
    padding: 1rem;
  }

  .custom-invoice-detail-list > div {
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }

  .custom-invoice-detail-list > div:last-child {
    border-bottom: 0;
  }

  .custom-invoice-recipient-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .custom-invoice-recipient-table th,
  .custom-invoice-recipient-table td {
    padding: .7rem .75rem;
  }
}


/* Custom invoice recovery and suffix-resume states */
.custom-invoice-recovery {
  margin-bottom: 1.15rem;
  border-color: color-mix(in srgb, var(--brand) 24%, var(--border));
}

.custom-invoice-recovery .staff-card-heading,
.custom-invoice-existing-assessment .staff-card-heading {
  padding: 1.15rem 1.35rem 1rem;
  border-bottom: 1px solid var(--border);
}

.custom-invoice-recovery-list {
  display: grid;
  gap: .75rem;
  padding: 1rem 1.35rem 1.25rem;
}

.custom-invoice-recovery-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 1rem;
  align-items: center;
  padding: .95rem 1rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface-2);
}

.custom-invoice-recovery-main {
  min-width: 0;
}

.custom-invoice-recovery-title {
  display: flex;
  flex-wrap: wrap;
  gap: .45rem .6rem;
  align-items: center;
  margin-bottom: .45rem;
}

.custom-invoice-recovery-title strong {
  color: var(--text-strong);
  font-size: .86rem;
}

.custom-invoice-recovery-title code {
  padding: .16rem .42rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface);
  color: var(--text-strong);
  font-size: .72rem;
  font-weight: 800;
}

.custom-invoice-recovery-meta {
  display: flex;
  flex-wrap: wrap;
  gap: .3rem .95rem;
  color: var(--muted);
  font-size: .72rem;
  line-height: 1.45;
}

.custom-invoice-recovery-error {
  margin: .55rem 0 0;
  color: var(--danger);
  font-size: .7rem;
  line-height: 1.45;
}

.custom-invoice-recovery-action form,
.custom-invoice-existing-actions form {
  margin: 0;
}

.custom-invoice-processing-label,
.custom-invoice-complete-label {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: .45rem .7rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface-2);
  color: var(--muted);
  font-size: .72rem;
  font-weight: 750;
}

.custom-invoice-existing-assessment {
  margin-bottom: 1rem;
  overflow: hidden;
}

.custom-invoice-existing-assessment.is-failed {
  border-color: color-mix(in srgb, var(--danger) 38%, var(--border));
}

.custom-invoice-existing-assessment.is-active {
  border-color: color-mix(in srgb, var(--brand) 34%, var(--border));
}

.custom-invoice-existing-assessment.is-complete {
  border-color: color-mix(in srgb, var(--success) 38%, var(--border));
}

.custom-invoice-existing-assessment .staff-card-heading {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: flex-start;
}

.custom-invoice-existing-assessment .staff-card-heading > div {
  min-width: 0;
  max-width: 780px;
}

.custom-invoice-existing-assessment .staff-card-heading h3 {
  margin: .2rem 0 .3rem;
  color: var(--text-strong);
  font-size: 1rem;
}

.custom-invoice-existing-assessment .staff-card-heading p {
  margin: 0;
  color: var(--muted);
  font-size: .78rem;
  line-height: 1.55;
}

.custom-invoice-existing-assessment > .staff-card-body {
  padding: 1.2rem 1.35rem 1.3rem;
}

.custom-invoice-existing-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: .7rem;
  margin-bottom: .9rem;
}

.custom-invoice-existing-stats > div {
  padding: .8rem .9rem;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: var(--surface-2);
}

.custom-invoice-existing-stats span,
.custom-invoice-existing-details dt {
  display: block;
  margin-bottom: .28rem;
  color: var(--muted);
  font-size: .64rem;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.custom-invoice-existing-stats strong {
  color: var(--text-strong);
  font-size: 1rem;
}

.custom-invoice-existing-details {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 0 0 .9rem;
  border: 1px solid var(--border);
  border-radius: 9px;
  overflow: hidden;
}

.custom-invoice-existing-details > div {
  padding: .75rem .85rem;
  border-right: 1px solid var(--border);
}

.custom-invoice-existing-details > div:last-child {
  border-right: 0;
}

.custom-invoice-existing-details dd {
  margin: 0;
  color: var(--text-strong);
  font-size: .78rem;
  font-weight: 740;
}

.custom-invoice-existing-differences,
.custom-invoice-existing-error {
  margin-top: .8rem;
  padding: .8rem .9rem;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: var(--surface-2);
  color: var(--text);
  font-size: .74rem;
  line-height: 1.5;
}

.custom-invoice-existing-differences strong,
.custom-invoice-existing-error strong {
  display: block;
  margin-bottom: .2rem;
  color: var(--text-strong);
}

.custom-invoice-existing-differences p,
.custom-invoice-existing-error p {
  margin: .3rem 0 0;
}

.custom-invoice-existing-error {
  border-color: color-mix(in srgb, var(--danger) 28%, var(--border));
}

.custom-invoice-existing-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: .65rem;
  align-items: center;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
}

@media (max-width: 760px) {
  .custom-invoice-recovery-row {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .custom-invoice-recovery-action .button,
  .custom-invoice-existing-actions .button {
    width: 100%;
  }

  .custom-invoice-existing-assessment .staff-card-heading {
    flex-direction: column;
  }

  .custom-invoice-existing-stats,
  .custom-invoice-existing-details {
    grid-template-columns: 1fr;
  }

  .custom-invoice-existing-details > div {
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }

  .custom-invoice-existing-details > div:last-child {
    border-bottom: 0;
  }

  .custom-invoice-existing-actions {
    display: grid;
    grid-template-columns: 1fr;
  }
}

.custom-invoice-preview-layout.is-existing {
  grid-template-columns: minmax(0, 1fr);
}

.custom-invoice-table-resume .button {
  min-height: 34px;
  padding: .42rem .7rem;
  font-size: .72rem;
}
/* ===== END pages/billing.css ===== */

/* ===== BEGIN pages/ledger.css ===== */
/*
 * ARBS stylesheet: pages/ledger.css
 * Purpose: General ledger, journals and trial-balance presentation.
 * Architecture: Page layer; ledger-only selectors.
 */

.ledger-page {
   display:grid;
   gap:1.35rem
}
 .ledger-page-header {
   display:flex;
   align-items:flex-start;
   justify-content:space-between;
   gap:1.5rem
}
 .ledger-page-heading {
   max-width:780px
}
 .ledger-eyebrow {
   display:block;
   margin-bottom:.3rem;
   color:var(--brand);
   font-size:.7rem;
   font-weight:850;
   letter-spacing:.09em;
   text-transform:uppercase
}
 .ledger-page-heading h2 {
   margin:0;
   color:var(--text-strong);
   font-size:1.5rem;
   letter-spacing:-.025em
}
 .ledger-page-heading p {
   margin:.45rem 0 0;
   color:var(--muted);
   line-height:1.6
}
 .ledger-filter-card {
   display:grid;
   grid-template-columns:minmax(180px,1fr) minmax(145px,.65fr) minmax(145px,.65fr) minmax(260px,1.4fr) auto;
   gap:1rem;
   align-items:end;
   padding:1.2rem 1.3rem;
   border:1px solid var(--border);
   border-radius:16px;
   background:var(--surface);
   box-shadow:var(--shadow-sm)
}
 .ledger-filter-field {
   display:grid;
   gap:.42rem;
   min-width:0
}
 .ledger-filter-field label {
   color:var(--text-strong);
   font-size:.76rem;
   font-weight:800
}
 .ledger-filter-field input,.ledger-filter-field select {
   width:100%;
   height:44px;
   box-sizing:border-box
}
 .ledger-filter-actions {
   display:flex;
   align-items:flex-end
}
 .ledger-filter-actions .button {
   height:44px;
   white-space:nowrap
}
 .ledger-integrity-card {
   display:grid;
   grid-template-columns:52px minmax(0,1fr);
   gap:1rem;
   align-items:start;
   padding:1.2rem 1.3rem;
   border:1px solid var(--border);
   border-radius:16px;
   box-shadow:var(--shadow-sm)
}
 .ledger-integrity-card.is-balanced {
   border-color:var(--success-border);
   background:var(--success-soft)
}
 .ledger-integrity-card.is-error {
   border-color:var(--danger-border);
   background:var(--danger-soft)
}
 .ledger-integrity-icon {
   display:grid;
   place-items:center;
   width:52px;
   height:52px;
   border-radius:14px;
   color:#fff
}
 .ledger-integrity-card.is-balanced .ledger-integrity-icon {
   background:var(--success)
}
 .ledger-integrity-card.is-error .ledger-integrity-icon {
   background:var(--danger)
}
 .ledger-integrity-icon svg {
   width:27px;
   height:27px
}
 .ledger-integrity-label {
   display:block;
   margin-bottom:.25rem;
   color:var(--muted);
   font-size:.7rem;
   font-weight:850;
   letter-spacing:.08em;
   text-transform:uppercase
}
 .ledger-integrity-card strong {
   display:block;
   color:var(--text-strong);
   font-size:1.05rem
}
 .ledger-integrity-card p {
   margin:.35rem 0 0;
   color:var(--text);
   line-height:1.55
}
 .ledger-integrity-card ul {
   margin:.55rem 0 0;
   padding-left:1.2rem;
   color:var(--text);
   line-height:1.55
}
 .ledger-summary-grid {
   display:grid;
   grid-template-columns:repeat(4,minmax(0,1fr));
   gap:1rem
}
 .ledger-summary-card {
   display:grid;
   grid-template-columns:48px minmax(0,1fr);
   gap:.9rem;
   align-items:start;
   min-width:0;
   padding:1.15rem;
   border:1px solid var(--border);
   border-radius:16px;
   background:var(--surface);
   box-shadow:var(--shadow-sm)
}
 .ledger-summary-icon {
   display:grid;
   place-items:center;
   width:48px;
   height:48px;
   border-radius:13px;
   background:var(--brand-soft);
   color:var(--brand)
}
 .ledger-summary-icon svg {
   width:24px;
   height:24px
}
 .ledger-summary-card span {
   display:block;
   color:var(--muted);
   font-size:.72rem;
   font-weight:800;
   letter-spacing:.055em;
   text-transform:uppercase
}
 .ledger-summary-card strong {
   display:block;
   margin:.38rem 0 .35rem;
   color:var(--text-strong);
   font-size:1.25rem;
   line-height:1.25;
   overflow-wrap:anywhere
}
 .ledger-summary-card small {
   display:block;
   color:var(--muted);
   font-size:.78rem;
   line-height:1.45
}
 .ledger-card {
   overflow:hidden;
   border:1px solid var(--border);
   border-radius:18px;
   background:var(--surface);
   box-shadow:var(--shadow-sm)
}
 .ledger-card-header {
   display:flex;
   align-items:flex-start;
   justify-content:space-between;
   gap:1.25rem;
   padding:1.35rem 1.4rem;
   border-bottom:1px solid var(--border);
   background:linear-gradient(180deg,color-mix(in srgb,var(--brand) 5%,var(--surface)),var(--surface))
}
 .ledger-card-title {
   display:grid;
   grid-template-columns:52px minmax(0,1fr);
   gap:1rem;
   min-width:0
}
 .ledger-card-icon {
   display:grid;
   place-items:center;
   width:52px;
   height:52px;
   border-radius:15px;
   background:var(--brand-soft);
   color:var(--brand)
}
 .ledger-card-icon svg {
   width:27px;
   height:27px
}
 .ledger-card-title h3 {
   margin:0;
   color:var(--text-strong);
   font-size:1.18rem
}
 .ledger-card-title p {
   max-width:720px;
   margin:.4rem 0 0;
   color:var(--muted);
   font-size:.86rem;
   line-height:1.55
}
 .ledger-balance-summary {
   display:grid;
   grid-template-columns:repeat(2,minmax(145px,1fr));
   gap:.75rem;
   flex:0 0 auto
}
 .ledger-balance-summary>div {
   min-width:0;
   padding:.8rem .9rem;
   border:1px solid var(--border);
   border-radius:12px;
   background:var(--surface-2);
   text-align:right
}
 .ledger-balance-summary span {
   display:block;
   color:var(--muted);
   font-size:.68rem;
   font-weight:800;
   letter-spacing:.065em;
   text-transform:uppercase
}
 .ledger-balance-summary strong {
   display:block;
   margin-top:.3rem;
   color:var(--text-strong);
   font-size:.95rem;
   overflow-wrap:anywhere
}
 .ledger-table-wrap {
   overflow-x:auto
}
 .ledger-table {
   width:100%;
   min-width:780px;
   table-layout:auto;
   border-collapse:collapse
}
 .ledger-table th {
   padding:.85rem 1rem;
   background:var(--surface-2);
   color:var(--muted);
   font-size:.7rem;
   font-weight:850;
   letter-spacing:.055em;
   text-transform:uppercase;
   white-space:nowrap
}
 .ledger-table td {
   padding:1rem;
   border-top:1px solid var(--border);
   color:var(--text);
   vertical-align:middle
}
 .ledger-table tbody tr:hover {
   background:color-mix(in srgb,var(--brand) 4%,transparent)
}
 .ledger-table .num {
   text-align:right;
   font-variant-numeric:tabular-nums;
   white-space:nowrap
}
 .ledger-account-link {
   display:grid;
   gap:.18rem;
   color:inherit;
   text-decoration:none
}
 .ledger-account-link strong {
   color:var(--brand);
   font-size:.78rem
}
 .ledger-account-link span {
   color:var(--text-strong);
   font-weight:750
}
 .ledger-account-link:hover span,.ledger-reference-link:hover {
   text-decoration:underline
}
 .ledger-type-pill,.ledger-status-pill {
   display:inline-flex;
   align-items:center;
   min-height:28px;
   padding:.32rem .58rem;
   border:1px solid var(--border);
   border-radius:999px;
   background:var(--surface-2);
   color:var(--text);
   font-size:.72rem;
   font-weight:750;
   white-space:nowrap
}
 .ledger-status-pill {
   border-color:var(--success-border);
   background:var(--success-soft);
   color:var(--success)
}
 .ledger-balance-cell,.ledger-amount-cell {
   color:var(--text-strong);
   font-weight:800
}
 .ledger-reference-link {
   color:var(--brand);
   font-weight:800;
   text-decoration:none
}
 .ledger-source {
   display:grid;
   gap:.18rem;
   color:var(--text-strong);
   font-weight:700
}
 .ledger-source small {
   color:var(--muted);
   font-size:.72rem;
   font-weight:500
}
 .ledger-empty-state {
   display:grid;
   gap:.25rem;
   padding:1.6rem;
   text-align:center
}
 .ledger-empty-state strong {
   color:var(--text-strong)
}
 .ledger-empty-state span {
   color:var(--muted)
}
 .ledger-journals-card {
   margin-top:.1rem
}
 .ledger-card-header--compact {
   align-items:center
}
 @media(max-width:1150px) {
   .ledger-filter-card {
     grid-template-columns:repeat(2,minmax(0,1fr))
  }
   .ledger-filter-community,.ledger-filter-search {
     grid-column:auto
  }
   .ledger-filter-actions {
     grid-column:1/-1
  }
   .ledger-filter-actions .button {
     width:100%
  }
   .ledger-summary-grid {
     grid-template-columns:repeat(2,minmax(0,1fr))
  }
   .ledger-card-header {
     flex-direction:column
  }
   .ledger-balance-summary {
     width:100%
  }

}
 @media(max-width:700px) {
   .ledger-page {
     gap:1rem
  }
   .ledger-filter-card,.ledger-summary-grid {
     grid-template-columns:1fr
  }
   .ledger-filter-actions {
     grid-column:auto
  }
   .ledger-integrity-card {
     grid-template-columns:44px minmax(0,1fr);
     padding:1rem
  }
   .ledger-integrity-icon {
     width:44px;
     height:44px;
     border-radius:12px
  }
   .ledger-summary-card {
     padding:1rem
  }
   .ledger-card-header {
     padding:1.05rem
  }
   .ledger-card-title {
     grid-template-columns:44px minmax(0,1fr)
  }
   .ledger-card-icon {
     width:44px;
     height:44px;
     border-radius:12px
  }
   .ledger-balance-summary {
     grid-template-columns:1fr
  }
   .ledger-balance-summary>div {
     text-align:left
  }
   .ledger-table th,.ledger-table td {
     padding:.8rem
  }
   .ledger-page-heading h2 {
     font-size:1.35rem
  }

}

/* General-ledger phone layout. */
@media (max-width: 760px) {
  .ledger-filter-card,
  .ledger-summary-grid,
  .ledger-balance-summary { grid-template-columns: minmax(0, 1fr); }
  .ledger-filter-card > *,
  .ledger-summary-grid > *,
  .ledger-balance-summary > * { min-width: 0; }
}
/* ===== END pages/ledger.css ===== */

/* ===== BEGIN pages/reports.css ===== */
/*
 * ARBS stylesheet: pages/reports.css
 * Purpose: Reporting centre and property-statement selector/detail layouts.
 * Architecture: Page layer; report-only selectors.
 */

.property-statements-page {
   display:grid;
   gap:22px
}
 .property-statements-hero {
   display:flex;
   align-items:flex-start;
   gap:18px;
   padding:26px 28px;
   border:1px solid var(--border);
   border-radius:16px;
   background:linear-gradient(135deg,var(--surface),var(--surface-2));
   box-shadow:var(--shadow-sm)
}
 .property-statements-hero-icon {
   display:grid;
   place-items:center;
   flex:0 0 52px;
   width:52px;
   height:52px;
   border-radius:14px;
   background:var(--brand-soft);
   color:var(--button-primary)
}
 .property-statements-hero-icon svg {
   width:27px;
   height:27px
}
 .property-statements-hero h2 {
   margin:3px 0 7px;
   font-size:24px
}
 .property-statements-hero p {
   max-width:760px;
   margin:0;
   color:var(--muted);
   line-height:1.65
}
 .property-statements-hero .eyebrow {
   color:var(--button-primary);
   font-size:12px;
   font-weight:750;
   letter-spacing:.08em;
   text-transform:uppercase
}
 .property-statement-search-card {
   display:grid;
   grid-template-columns:minmax(260px,.8fr) minmax(460px,1.4fr);
   align-items:end;
   gap:24px;
   padding:22px 24px;
   border:1px solid var(--border);
   border-radius:14px;
   background:var(--surface)
}
 .property-statement-search-copy h3,.property-statements-results-head h3 {
   margin:0 0 5px
}
 .property-statement-search-copy p,.property-statements-results-head p {
   margin:0;
   color:var(--muted);
   line-height:1.55
}
 .property-statement-search-form {
   display:flex;
   align-items:center;
   gap:10px
}
 .property-statement-search-input {
   display:flex;
   align-items:center;
   gap:10px;
   min-width:0;
   flex:1;
   height:46px;
   padding:0 14px;
   border:1px solid var(--border);
   border-radius:10px;
   background:var(--surface)
}
 .property-statement-search-input:focus-within {
   border-color:var(--button-primary);
   box-shadow:0 0 0 3px var(--button-primary-focus)
}
 .property-statement-search-input span {
   color:var(--muted);
   font-size:20px
}
 .property-statement-search-input input {
   width:100%;
   border:0;
   outline:0;
   background:transparent;
   color:var(--text);
   font:inherit
}
 .property-statements-results-head {
   display:flex;
   align-items:center;
   justify-content:space-between;
   gap:16px
}
 .property-statement-grid {
   display:grid;
   grid-template-columns:repeat(3,minmax(0,1fr));
   gap:18px
}
 .property-statement-card {
   display:flex;
   flex-direction:column;
   min-width:0;
   padding:20px;
   border:1px solid var(--border);
   border-radius:14px;
   background:var(--surface);
   box-shadow:var(--shadow-sm)
}
 .property-statement-card-head {
   display:grid;
   grid-template-columns:auto minmax(0,1fr) auto;
   align-items:start;
   gap:12px;
   padding-bottom:16px;
   border-bottom:1px solid var(--border)
}
 .property-statement-plot-icon {
   display:grid;
   place-items:center;
   width:42px;
   height:42px;
   border-radius:11px;
   background:var(--brand-soft);
   color:var(--button-primary);
   font-size:12px;
   font-weight:800
}
 .property-statement-card-head h3 {
   margin:2px 0;
   font-size:19px
}
 .property-statement-card-head p,.property-statement-kicker {
   margin:0;
   color:var(--muted);
   font-size:12px
}
 .property-statement-kicker {
   font-weight:700;
   text-transform:uppercase;
   letter-spacing:.05em
}
 .property-statement-details {
   display:grid;
   gap:0;
   margin:8px 0 18px
}
 .property-statement-details>div {
   display:grid;
   grid-template-columns:minmax(105px,.8fr) minmax(0,1.3fr);
   gap:12px;
   padding:10px 0;
   border-bottom:1px solid var(--border)
}
 .property-statement-details dt {
   color:var(--muted);
   font-size:12px
}
 .property-statement-details dd {
   margin:0;
   text-align:right;
   color:var(--text-strong);
   font-size:12px;
   font-weight:650;
   overflow-wrap:anywhere
}
 .property-statement-card-action {
   margin-top:auto
}
 .property-statement-card-action .button {
   width:100%;
   justify-content:center
}
 .property-statement-empty {
   grid-column:1/-1;
   padding:36px
}
 .property-statements-page>.pagination {
   margin-top:0
}
 @media(max-width:1100px) {
   .property-statement-grid {
     grid-template-columns:repeat(2,minmax(0,1fr))
  }
   .property-statement-search-card {
     grid-template-columns:1fr
  }

}
 @media(max-width:700px) {
   .property-statements-hero {
     padding:20px;
     flex-direction:column
  }
   .property-statement-search-card {
     padding:18px
  }
   .property-statement-search-form {
     align-items:stretch;
     flex-direction:column
  }
   .property-statement-search-form .button {
     width:100%;
     justify-content:center
  }
   .property-statements-results-head {
     align-items:flex-start;
     flex-direction:column
  }
   .property-statement-grid {
     grid-template-columns:1fr
  }
   .property-statement-card-head {
     grid-template-columns:auto minmax(0,1fr)
  }
   .property-statement-card-head>.badge {
     grid-column:2
  }
   .property-statement-details>div {
     grid-template-columns:1fr;
     gap:3px
  }
   .property-statement-details dd {
     text-align:left
  }

}

/* Report and statement phone layout. */
@media (max-width: 760px) {
  .property-statement-search-card,
  .property-statement-grid { grid-template-columns: minmax(0, 1fr); }
  .property-statement-search-card > *,
  .property-statement-grid > * { min-width: 0; }
}



/* Reconciliation exception report remains a readable table on narrow screens. */
.reconciliation-exceptions-table {
  min-width: 900px;
}

.reconciliation-exceptions-table th,
.reconciliation-exceptions-table td {
  white-space: nowrap;
}

.reconciliation-exceptions-table td:nth-child(3),
.reconciliation-exceptions-table td:nth-child(4) {
  white-space: normal;
}

.special-levy-export-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
/* ===== END pages/reports.css ===== */

/* ===== BEGIN pages/invoices.css ===== */
/*
 * ARBS stylesheet: pages/invoices.css
 * Purpose: Invoice register, invoice detail and allocation tables.
 * Architecture: Page layer; invoice-only selectors.
 */

.invoice-guidance-grid {
   display:grid;
   grid-template-columns:repeat(2,minmax(0,1fr));
   gap:16px;
   margin:0 0 20px
}
 .invoice-guidance-card {
   display:grid;
   grid-template-columns:48px minmax(0,1fr);
   gap:16px;
   align-items:start;
   min-width:0;
   padding:21px 22px;
   border:1px solid var(--border);
   border-radius:16px;
   background:var(--surface);
   box-shadow:var(--shadow-sm)
}
 .invoice-guidance-card__icon {
   display:grid;
   place-items:center;
   width:48px;
   height:48px;
   border:1px solid color-mix(in srgb,var(--brand) 24%,var(--border));
   border-radius:14px;
   background:var(--brand-soft);
   color:var(--brand)
}
 .invoice-guidance-card__icon svg {
   width:24px;
   height:24px
}
 .invoice-guidance-card h3 {
   margin:1px 0 6px;
   color:var(--text-strong);
   font-size:17px;
   line-height:1.3
}
 .invoice-guidance-card p {
   margin:0;
   color:var(--muted);
   line-height:1.58
}
 @media(max-width:760px) {
   .invoice-guidance-grid {
     grid-template-columns:1fr
  }
   .invoice-guidance-card {
     padding:18px
  }

}
 /* ARBS modular stylesheet: pages/invoices.css */
 /* Invoice detail summary cards */
 .invoice-summary-grid {
   display:grid;
   grid-template-columns:minmax(0,1.35fr) minmax(320px,.85fr);
   gap:20px;
   margin:20px 0
}
 .invoice-summary-card {
   min-width:0;
   overflow:hidden;
   border:1px solid var(--border);
   border-radius:16px;
   background:var(--surface);
   box-shadow:var(--shadow-sm)
}
 .invoice-summary-card__header {
   display:flex;
   align-items:flex-start;
   gap:14px;
   padding:22px 24px 19px;
   border-bottom:1px solid var(--border);
   background:linear-gradient(135deg,var(--brand-soft),var(--surface))
}
 .invoice-summary-card__header>div {
   min-width:0
}
 .invoice-summary-card__header h3 {
   margin:3px 0 5px;
   color:var(--text-strong);
   font-size:19px;
   line-height:1.25
}
 .invoice-summary-card__header p {
   max-width:620px;
   margin:0;
   color:var(--muted);
   font-size:13px;
   line-height:1.55
}
 .invoice-summary-card__icon {
   display:grid;
   flex:0 0 42px;
   width:42px;
   height:42px;
   place-items:center;
   border:1px solid color-mix(in srgb,var(--brand) 25%,var(--border));
   border-radius:12px;
   background:var(--surface);
   color:var(--brand)
}
 .invoice-summary-card__icon svg {
   width:22px;
   height:22px
}
 .invoice-information-grid {
   display:grid;
   grid-template-columns:repeat(2,minmax(0,1fr));
   margin:0;
   padding:6px 24px 22px
}
 .invoice-information-grid>div {
   min-width:0;
   padding:16px 4px;
   border-bottom:1px solid var(--border)
}
 .invoice-information-grid>div:nth-last-child(-n+2) {
   border-bottom:0
}
 .invoice-information-grid>div:nth-child(odd):not(.invoice-information-grid__wide) {
   padding-right:18px;
   border-right:1px solid var(--border)
}
 .invoice-information-grid>div:nth-child(even):not(.invoice-information-grid__wide) {
   padding-left:18px
}
 .invoice-information-grid__wide {
   grid-column:1/-1
}
 .invoice-information-grid dt,.invoice-totals-list dt {
   margin:0 0 6px;
   color:var(--muted);
   font-size:11px;
   font-weight:800;
   letter-spacing:.055em;
   text-transform:uppercase
}
 .invoice-information-grid dd {
   min-width:0;
   margin:0;
   color:var(--text-strong);
   font-weight:650;
   line-height:1.5;
   overflow-wrap:anywhere
}
 .invoice-totals-list {
   display:grid;
   gap:0;
   margin:0;
   padding:8px 24px 14px
}
 .invoice-totals-list>div {
   display:flex;
   align-items:center;
   justify-content:space-between;
   gap:20px;
   padding:13px 2px;
   border-bottom:1px solid var(--border)
}
 .invoice-totals-list>div:last-child {
   border-bottom:0
}
 .invoice-totals-list dt {
   margin:0
}
 .invoice-totals-list dd {
   margin:0;
   color:var(--text-strong);
   font-variant-numeric:tabular-nums;
   font-weight:700;
   text-align:right;
   white-space:nowrap
}
 .invoice-totals-list__total {
   margin-top:3px;
   padding-top:16px;
   border-top:1px solid var(--border)
}
 .invoice-totals-list__total dt,.invoice-totals-list__total dd {
   color:var(--text-strong);
   font-size:15px;
   font-weight:800
}
 .invoice-totals-list__balance {
   margin:6px -10px 0;
   padding:15px 12px;
   border:1px solid color-mix(in srgb,var(--brand) 28%,var(--border));
   border-radius:11px;
   background:var(--brand-soft)
}
 .invoice-totals-list__balance dt {
   color:var(--brand);
   font-size:11px
}
 .invoice-totals-list__balance dd {
   color:var(--brand);
   font-size:18px;
   font-weight:850
}
 .invoice-totals-card__action {
   padding:0 24px 24px
}
 .invoice-totals-card__action .button {
   width:100%;
   min-height:46px;
   justify-content:center
}
 html.dark .invoice-summary-card__header {
   background:linear-gradient(135deg,#123d39,var(--surface))
}
 html.dark .invoice-totals-list__balance {
   background:#123d39
}
 @media(max-width:960px) {
   .invoice-summary-grid {
     grid-template-columns:1fr
  }

}
 @media(max-width:640px) {
   .invoice-summary-grid {
     gap:16px;
     margin:16px 0
  }
   .invoice-summary-card__header {
     padding:18px
  }
   .invoice-information-grid {
     grid-template-columns:1fr;
     padding:4px 18px 18px
  }
   .invoice-information-grid>div,.invoice-information-grid>div:nth-child(odd):not(.invoice-information-grid__wide),.invoice-information-grid>div:nth-child(even):not(.invoice-information-grid__wide) {
     grid-column:1;
     padding:14px 0;
     border-right:0;
     border-bottom:1px solid var(--border)
  }
   .invoice-information-grid>div:nth-last-child(-n+2) {
     border-bottom:1px solid var(--border)
  }
   .invoice-information-grid>div:last-child {
     border-bottom:0
  }
   .invoice-totals-list {
     padding:6px 18px 12px
  }
   .invoice-totals-list>div {
     gap:12px
  }
   .invoice-totals-list dd {
     white-space:normal
  }
   .invoice-totals-card__action {
     padding:0 18px 18px
  }

}
 /* Invoice line and payment allocation tables */
 .invoice-detail-table-stack {
   display:grid;
   gap:20px;
   margin-top:20px
}
 .invoice-detail-table-stack>.card {
   margin:0
}
 @media(max-width:640px) {
   .invoice-detail-table-stack {
     gap:16px;
     margin-top:16px
  }

}


/* Dense invoice register: preserve readable columns and let .table-wrap own overflow. */
.invoice-register-table {
  min-width: 980px;
}

.invoice-register-table th,
.invoice-register-table td {
  white-space: nowrap;
}

.invoice-register-table td:nth-child(1),
.invoice-register-table td:nth-child(2) {
  white-space: normal;
}

/* Invoice phone layout. */
@media (max-width: 760px) {
  .invoice-summary-grid,
  .invoice-content-grid,
  .invoice-information-grid,
  .invoice-guidance-grid { grid-template-columns: minmax(0, 1fr); }
  .invoice-summary-grid > *,
  .invoice-content-grid > *,
  .invoice-information-grid > *,
  .invoice-guidance-grid > * { min-width: 0; }
}
/* ===== END pages/invoices.css ===== */

/* ===== BEGIN pages/payments.css ===== */
/*
 * ARBS stylesheet: pages/payments.css
 * Purpose: Payments management, record payment and reconciliation workflows.
 * Architecture: Page layer; payment-only selectors.
 */

.payment-page {
   display:grid;
   gap:20px
}
 .payment-hero,.payment-list-header {
   display:flex;
   align-items:flex-start;
   justify-content:space-between;
   gap:24px;
   padding:22px 24px;
   border:1px solid var(--border);
   border-radius:var(--radius);
   background:var(--surface);
   box-shadow:var(--shadow-sm)
}
 .payment-hero__identity h2,.payment-list-header h2 {
   margin:3px 0 7px;
   color:var(--text-strong);
   font-size:24px;
   letter-spacing:-.025em
}
 .payment-eyebrow,.payment-section-kicker {
   display:block;
   color:var(--brand);
   font-size:11px;
   font-weight:800;
   letter-spacing:.12em;
   text-transform:uppercase
}
 .payment-hero__meta {
   display:flex;
   flex-wrap:wrap;
   align-items:center;
   gap:8px;
   color:var(--muted);
   font-size:14px
}
 .payment-reference {
   overflow-wrap:anywhere
}
 .payment-hero__actions {
   display:flex;
   align-items:center;
   justify-content:flex-end;
   gap:10px;
   flex-wrap:wrap
}
 .payment-summary-grid {
   display:grid;
   grid-template-columns:repeat(4,minmax(0,1fr));
   gap:14px
}
 .payment-summary-card {
   min-width:0;
   padding:18px 20px;
   border:1px solid var(--border);
   border-radius:14px;
   background:var(--surface);
   box-shadow:var(--shadow-sm)
}
 .payment-summary-card span {
   display:block;
   margin-bottom:8px;
   color:var(--muted);
   font-size:12px;
   font-weight:700;
   text-transform:uppercase;
   letter-spacing:.05em
}
 .payment-summary-card strong {
   display:block;
   color:var(--text-strong);
   font-size:20px;
   line-height:1.25;
   overflow-wrap:anywhere
}
 .payment-content-grid {
   display:grid;
   grid-template-columns:minmax(0,1.05fr) minmax(0,.95fr);
   gap:18px
}
 .payment-panel,.payment-filter-panel,.payment-management-card {
   min-width:0;
   border:1px solid var(--border);
   border-radius:16px;
   background:var(--surface);
   box-shadow:var(--shadow-sm)
}
 .payment-panel__header {
   display:flex;
   align-items:flex-start;
   justify-content:space-between;
   gap:16px;
   padding:20px 22px 16px;
   border-bottom:1px solid var(--border)
}
 .payment-panel__header h3,.payment-management-heading h3,.payment-management-card__header h3 {
   margin:3px 0 0;
   color:var(--text-strong);
   font-size:20px
}
 .payment-detail-list {
   margin:0;
   padding:8px 22px 18px
}
 .payment-detail-list>div {
   display:grid;
   grid-template-columns:minmax(150px,.45fr) minmax(0,1fr);
   gap:18px;
   padding:13px 0;
   border-bottom:1px solid var(--border)
}
 .payment-detail-list>div:last-child {
   border-bottom:0
}
 .payment-detail-list dt {
   color:var(--muted);
   font-size:13px;
   font-weight:700
}
 .payment-detail-list dd {
   min-width:0;
   margin:0;
   color:var(--text);
   font-weight:600
}
 .payment-break-text {
   overflow-wrap:anywhere;
   word-break:break-word
}
 .payment-muted {
   color:var(--muted)
}
 .payment-allocation-options {
   display:grid;
   gap:14px;
   padding:18px 22px 22px
}
 .payment-action-block {
   display:grid;
   gap:14px;
   padding:16px;
   border:1px solid var(--border);
   border-radius:12px;
   background:var(--surface-2,#f8faf9)
}
 .payment-action-block--subtle {
   background:transparent
}
 .payment-action-block h4,.payment-guidance-item h4 {
   margin:0 0 5px;
   color:var(--text-strong);
   font-size:15px
}
 .payment-action-block p,.payment-guidance-item p,.payment-reversal-copy p {
   margin:0;
   color:var(--muted);
   line-height:1.55
}
 .payment-form-grid {
   display:grid;
   gap:14px
}
 .payment-form-grid--two-column {
   grid-template-columns:repeat(2,minmax(0,1fr));
   padding:22px
}
 .payment-field {
   min-width:0;
   display:grid;
   gap:7px
}
 .payment-field label {
   color:var(--text);
   font-size:13px;
   font-weight:800
}
 .payment-field small {
   color:var(--muted);
   line-height:1.4
}
 .payment-field input,.payment-field select,.payment-field textarea {
   width:100%;
   max-width:100%;
   box-sizing:border-box
}
 .payment-field--wide {
   grid-column:1/-1
}
 .payment-form-actions {
   display:flex;
   align-items:center;
   justify-content:flex-end;
   gap:10px;
   padding-top:8px
}
 .payment-empty-note,.payment-empty-state {
   padding:20px;
   color:var(--muted);
   text-align:center
}
 .payment-empty-state {
   display:grid;
   gap:4px
}
 .payment-allocation-table {
   min-width:760px
}
 .payment-allocation-table td {
   vertical-align:middle
}
 .payment-management-section {
   display:grid;
   gap:16px
}
 .payment-management-heading {
   padding:4px 2px
}
 .payment-management-heading p {
   max-width:850px;
   margin:7px 0 0;
   color:var(--muted);
   line-height:1.55
}
 .payment-management-grid {
   display:grid;
   grid-template-columns:minmax(0,1.35fr) minmax(300px,.65fr);
   gap:18px;
   align-items:start
}
 .payment-management-grid--single {
   grid-template-columns:minmax(0,1fr)
}
 .payment-management-card {
   overflow:hidden
}
 .payment-management-card__header {
   display:flex;
   align-items:center;
   gap:13px;
   padding:19px 21px;
   border-bottom:1px solid var(--border)
}
 .payment-management-icon {
   display:grid;
   place-items:center;
   flex:0 0 38px;
   width:38px;
   height:38px;
   border-radius:11px;
   background:rgba(22,101,52,.1);
   color:var(--brand);
   font-size:22px;
   font-weight:900
}
 .payment-management-icon--danger {
   background:rgba(185,28,28,.1);
   color:#b91c1c
}
 .payment-guidance-card {
   margin:18px 20px 0;
   padding:4px 18px;
   border:1px solid var(--border);
   border-radius:13px;
   background:var(--surface-2,#f8faf9)
}
 .payment-guidance-item {
   display:grid;
   grid-template-columns:30px minmax(0,1fr);
   gap:12px;
   padding:16px 0
}
 .payment-guidance-item+.payment-guidance-item {
   border-top:1px solid var(--border)
}
 .payment-guidance-number {
   display:grid;
   place-items:center;
   width:28px;
   height:28px;
   border-radius:50%;
   background:var(--brand);
   color:#fff;
   font-size:13px;
   font-weight:900
}
 .payment-guidance-item p+p {
   margin-top:7px
}
 .payment-warning {
   margin:14px 20px 0;
   padding:13px 15px;
   border:1px solid rgba(180,83,9,.24);
   border-radius:11px;
   background:rgba(245,158,11,.09);
   color:var(--text);
   font-size:13px;
   line-height:1.5
}
 .payment-warning strong {
   color:#92400e
}
 .payment-management-form {
   padding:18px 20px 21px
}
 .payment-management-form .button {
   justify-self:start
}
 .payment-management-card--reverse {
   border-color:rgba(185,28,28,.23)
}
 .payment-reversal-copy {
   display:grid;
   gap:12px;
   padding:18px 20px 0;
   color:var(--muted)
}
 .payment-reversal-copy ul {
   margin:0;
   padding-left:20px;
   display:grid;
   gap:7px;
   line-height:1.45
}
 .payment-filter-panel {
   padding:18px
}
 .payment-filter-grid {
   display:grid;
   grid-template-columns:minmax(280px,2fr) repeat(3,minmax(150px,1fr));
   gap:13px;
   align-items:end
}
 .payment-filter-search {
   grid-column:span 2
}
 .payment-filter-actions {
   display:flex;
   align-items:center;
   gap:9px;
   grid-column:span 2
}
 .payment-list-header p {
   margin:0;
   color:var(--muted)
}
 .payment-list-panel {
   overflow:hidden
}
 .payment-list-table {
   min-width:1180px
}
 .payment-list-table th {
   white-space:nowrap
}
 .payment-list-table td {
   vertical-align:middle
}
 .payment-table-subtext {
   display:block;
   margin-top:4px;
   color:var(--muted);
   font-size:12px;
   max-width:220px;
   overflow-wrap:anywhere
}
 .payment-row-action {
   text-align:right
}
 .payment-status {
   display:inline-flex;
   align-items:center;
   justify-content:center;
   max-width:100%;
   padding:5px 9px;
   border-radius:999px;
   background:var(--surface-2,#eef2ef);
   color:var(--text);
   font-size:11px;
   font-weight:800;
   line-height:1.1;
   white-space:nowrap
}
 .payment-status--reversed,.payment-status--failed {
   background:rgba(185,28,28,.1);
   color:#991b1b
}
 .payment-status--allocated,.payment-status--paid,.payment-status--completed {
   background:rgba(22,101,52,.1);
   color:#166534
}
 .payment-status--unallocated,.payment-status--pending,.payment-status--part_allocated {
   background:rgba(180,83,9,.1);
   color:#92400e
}
 .payment-status--unmatched {
   background:rgba(71,85,105,.12);
   color:#475569
}

/* Dense reconciliation register: preserve readable columns; wrapper scrolls locally. */
.reconciliation-register-table {
  min-width: 1040px;
}

.reconciliation-register-table th,
.reconciliation-register-table td {
  white-space: nowrap;
}

.reconciliation-register-table td:nth-child(3),
.reconciliation-register-table td:nth-child(4) {
  white-space: normal;
}

.reconciliation-register-table td:last-child {
  text-align: right;
}

.reconciliation-register-table td:last-child .button {
  min-width: max-content;
}

 .payment-form-panel {
   max-width:1000px;
   width:100%;
   justify-self:center
}
 @media(max-width:1100px) {
   .payment-summary-grid {
     grid-template-columns:repeat(2,minmax(0,1fr))
  }
   .payment-content-grid,.payment-management-grid {
     grid-template-columns:1fr
  }
   .payment-filter-grid {
     grid-template-columns:repeat(2,minmax(0,1fr))
  }
   .payment-filter-search {
     grid-column:1/-1
  }
   .payment-filter-actions {
     grid-column:1/-1
  }

}
 @media(max-width:680px) {
   .payment-hero,.payment-list-header {
     padding:18px;
     flex-direction:column
  }
   .payment-hero__actions {
     justify-content:flex-start
  }
   .payment-summary-grid,.payment-filter-grid,.payment-form-grid--two-column {
     grid-template-columns:1fr
  }
   .payment-filter-search,.payment-filter-actions,.payment-field--wide {
     grid-column:1
  }
   .payment-filter-actions {
     align-items:stretch;
     flex-direction:column
  }
   .payment-filter-actions .button,.payment-filter-actions .small-button {
     width:100%;
     justify-content:center
  }
   .payment-detail-list {
     padding-inline:17px
  }
   .payment-detail-list>div {
     grid-template-columns:1fr;
     gap:5px
  }
   .payment-panel__header {
     padding-inline:17px
  }
   .payment-allocation-options {
     padding-inline:17px
  }
   .payment-guidance-card,.payment-warning {
     margin-inline:15px
  }
   .payment-management-card__header,.payment-management-form,.payment-reversal-copy {
     padding-inline:15px
  }
   .payment-management-form .button {
     width:100%;
     justify-content:center
  }
   .payment-form-grid--two-column {
     padding:17px
  }
   .payment-form-actions {
     align-items:stretch;
     flex-direction:column-reverse
  }
   .payment-form-actions .button,.payment-form-actions .small-button {
     width:100%;
     justify-content:center
  }

}
 /* Invoice payment instructions */
 .payment-instructions-card {
   overflow:hidden;
   margin:20px 0;
   border:1px solid color-mix(in srgb,var(--brand) 26%,var(--border));
   border-radius:16px;
   background:var(--surface);
   box-shadow:var(--shadow-sm)
}
 .payment-instructions-card__header {
   display:flex;
   align-items:flex-start;
   justify-content:space-between;
   gap:18px;
   padding:21px 23px;
   border-bottom:1px solid var(--border);
   background:linear-gradient(135deg,var(--brand-soft),var(--surface))
}
 .payment-instructions-card__header h3 {
   margin:3px 0 4px;
   color:var(--text-strong);
   font-size:19px
}
 .payment-instructions-card__header p {
   max-width:720px;
   margin:0;
   color:var(--muted);
   font-size:13px;
   line-height:1.5
}
 .payment-reference-badge {
   display:inline-flex;
   flex:0 0 auto;
   align-items:center;
   padding:7px 11px;
   border:1px solid color-mix(in srgb,var(--brand) 30%,var(--border));
   border-radius:999px;
   background:var(--surface);
   color:var(--brand-deep);
   font-size:13px;
   font-weight:850;
   letter-spacing:.03em
}
 .payment-instructions-grid {
   display:grid;
   grid-template-columns:minmax(0,.75fr) minmax(0,1.25fr);
   gap:16px;
   padding:20px 23px
}
 .payment-method-card {
   display:grid;
   grid-template-columns:42px minmax(0,1fr);
   gap:13px;
   align-items:start;
   padding:16px;
   border:1px solid var(--border);
   border-radius:13px;
   background:var(--surface-2)
}
 .payment-method-card__icon {
   display:grid;
   place-items:center;
   width:42px;
   height:42px;
   border-radius:12px;
   background:var(--brand-soft);
   color:var(--brand-deep);
   font-size:15px;
   font-weight:900
}
 .payment-method-card h4 {
   margin:1px 0 10px;
   color:var(--text-strong);
   font-size:14px;
   letter-spacing:.04em
}
 .payment-method-details {
   display:grid;
   gap:7px;
   margin:0
}
 .payment-method-details>div {
   display:grid;
   grid-template-columns:minmax(95px,.42fr) minmax(0,1fr);
   gap:10px
}
 .payment-method-details dt {
   color:var(--muted);
   font-size:12px;
   font-weight:700
}
 .payment-method-details dd {
   min-width:0;
   margin:0;
   color:var(--text);
   font-size:13px;
   overflow-wrap:anywhere
}
 .payment-tracking-note {
   display:flex;
   align-items:flex-start;
   gap:9px;
   margin:0 23px 21px;
   padding:13px 15px;
   border:1px solid color-mix(in srgb,var(--warning) 34%,var(--border));
   border-radius:12px;
   background:var(--warning-soft);
   color:var(--text);
   font-size:13px;
   line-height:1.5
}
 .payment-tracking-note>strong {
   flex:0 0 auto;
   color:var(--text-strong)
}
 html.dark .payment-instructions-card__header {
   background:linear-gradient(135deg,#123d39,var(--surface))
}
 html.dark .payment-reference-badge {
   background:#10291f;
   color:#a8e4cf
}
 html.dark .payment-method-card {
   background:#142033
}
 @media(max-width:800px) {
   .payment-instructions-card__header {
     align-items:stretch;
     flex-direction:column;
     padding:18px
  }
   .payment-reference-badge {
     align-self:flex-start
  }
   .payment-instructions-grid {
     grid-template-columns:1fr;
     padding:17px 18px
  }
   .payment-tracking-note {
     align-items:stretch;
     flex-direction:column;
     margin:0 18px 18px
  }
   .payment-method-details>div {
     grid-template-columns:1fr;
     gap:2px
  }

}
 /* Manual payment entry */
 .record-payment-page {
   max-width:1180px;
   width:100%;
   margin-inline:auto
}
 .record-payment-header p {
   max-width:820px;
   line-height:1.55
}
 .record-payment-guidance {
   display:grid;
   grid-template-columns:repeat(2,minmax(0,1fr));
   gap:16px
}
 .record-payment-guidance__item {
   display:grid;
   grid-template-columns:44px minmax(0,1fr);
   gap:14px;
   align-items:start;
   padding:18px 20px;
   border:1px solid var(--border);
   border-radius:15px;
   background:var(--surface);
   box-shadow:var(--shadow-sm)
}
 .record-payment-guidance__icon {
   display:grid;
   place-items:center;
   width:44px;
   height:44px;
   border-radius:13px;
   background:var(--brand-soft);
   color:var(--brand-deep)
}
 .record-payment-guidance__icon svg {
   width:23px;
   height:23px;
   stroke:currentColor;
   stroke-width:1.8;
   stroke-linecap:round;
   stroke-linejoin:round
}
 .record-payment-guidance__item strong {
   display:block;
   color:var(--text-strong);
   font-size:15px
}
 .record-payment-guidance__item p {
   margin:5px 0 0;
   color:var(--muted);
   font-size:13px;
   line-height:1.5
}
 .record-payment-form {
   display:grid;
   gap:20px
}
 .record-payment-panel {
   overflow:hidden
}
 .record-payment-panel__header p {
   max-width:760px;
   margin:5px 0 0;
   color:var(--muted);
   font-size:13px;
   line-height:1.5
}
 .record-payment-grid {
   display:grid;
   gap:16px;
   padding:22px
}
 .record-payment-grid--identity {
   grid-template-columns:repeat(2,minmax(0,1fr))
}
 .record-payment-grid--financial {
   grid-template-columns:repeat(3,minmax(0,1fr))
}
 .record-payment-grid--notes {
   grid-template-columns:repeat(2,minmax(0,1fr))
}
 .record-payment-field--property {
   grid-column:1/-1
}
 .record-payment-field--wide {
   grid-column:1/-1
}
 .record-payment-field input,.record-payment-field select {
   min-height:46px
}
 .record-payment-field textarea {
   min-height:112px;
   resize:vertical
}
 .record-payment-allocation {
   padding:16px 18px;
   border:1px solid color-mix(in srgb,var(--brand) 26%,var(--border));
   border-radius:13px;
   background:var(--brand-soft)
}
 .record-payment-allocation>label {
   display:flex;
   align-items:flex-start;
   gap:12px;
   margin:0;
   cursor:pointer
}
 .record-payment-allocation input[type="checkbox"] {
   flex:0 0 auto;
   width:18px;
   height:18px;
   margin-top:2px;
   accent-color:var(--brand)
}
 .record-payment-allocation label>span {
   display:grid;
   gap:4px
}
 .record-payment-allocation strong {
   color:var(--text-strong);
   font-size:14px
}
 .record-payment-allocation small {
   color:var(--muted);
   font-size:12px;
   line-height:1.45
}
 .record-payment-form>.sticky-form-actions {
   margin-top:0
}
 @media(max-width:820px) {
   .record-payment-guidance,.record-payment-grid--identity,.record-payment-grid--financial,.record-payment-grid--notes {
     grid-template-columns:1fr
  }
   .record-payment-field--property,.record-payment-field--wide {
     grid-column:1
  }
   .record-payment-grid {
     padding:18px
  }

}
 @media(max-width:560px) {
   .record-payment-guidance__item {
     grid-template-columns:38px minmax(0,1fr);
     padding:16px
  }
   .record-payment-guidance__icon {
     width:38px;
     height:38px
  }
   .record-payment-grid {
     padding:16px
  }
   .record-payment-panel__header {
     padding:18px 16px
  }

}

/* Payments phone layout. */
@media (max-width: 760px) {
  .payment-summary-grid,
  .payment-content-grid,
  .payment-management-grid,
  .payment-instructions-grid,
  .record-payment-guidance,
  .record-payment-grid--identity,
  .record-payment-grid--financial,
  .record-payment-grid--notes { grid-template-columns: minmax(0, 1fr); }
  .payment-summary-grid > *,
  .payment-content-grid > *,
  .payment-management-grid > *,
  .payment-instructions-grid > *,
  .record-payment-guidance > * { min-width: 0; }
}
/* Reconciliation header export remains anchored to the trailing edge on phones. */
@media (max-width: 760px) {
  .reconciliation-export-action {
    align-self: flex-end;
    width: auto;
    max-width: 100%;
  }

  .reconciliation-export-action > summary {
    width: auto;
  }
}


/* Reconciliation allocation review workspace. */
.reconciliation-review-card {
  overflow:hidden
}
.reconciliation-review-header {
  align-items:flex-start;
  gap:24px;
  padding-bottom:18px
}
.reconciliation-review-header p {
  max-width:760px;
  margin:6px 0 0;
  color:var(--muted);
  line-height:1.5
}
.split-transaction-total {
  flex:0 0 auto;
  min-width:190px;
  padding:12px 14px;
  border:1px solid var(--border);
  border-radius:12px;
  background:var(--surface-2,#f8faf9);
  text-align:right
}
.split-transaction-total span,
.split-allocation-summary span,
.reconciliation-transaction-strip span {
  display:block;
  color:var(--muted);
  font-size:12px;
  font-weight:700;
  letter-spacing:.04em;
  text-transform:uppercase
}
.split-transaction-total strong {
  display:block;
  margin-top:4px;
  color:var(--text-strong);
  font-size:20px
}
.reconciliation-transaction-strip {
  display:grid;
  grid-template-columns:minmax(120px,.7fr) minmax(160px,1fr) minmax(160px,1fr) minmax(260px,1.8fr) minmax(120px,.7fr);
  gap:0;
  margin:0 22px;
  border:1px solid var(--border);
  border-radius:12px;
  background:var(--surface-2,#f8faf9);
  overflow:hidden
}
.reconciliation-transaction-strip>div {
  min-width:0;
  padding:13px 15px;
  border-right:1px solid var(--border)
}
.reconciliation-transaction-strip>div:last-child {
  border-right:0
}
.reconciliation-transaction-strip strong {
  display:block;
  margin-top:5px;
  color:var(--text-strong);
  font-size:14px;
  font-weight:700;
  line-height:1.4;
  overflow-wrap:break-word
}
.split-allocation-form {
  display:grid;
  gap:18px;
  padding:22px
}
.split-allocation-toolbar {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px
}
.split-allocation-toolbar strong,
.split-allocation-toolbar small {
  display:block
}
.split-allocation-toolbar small {
  margin-top:3px;
  color:var(--muted);
  line-height:1.45
}
.split-allocation-column-headings,
.split-allocation-row {
  display:grid;
  grid-template-columns:34px minmax(280px,1fr) minmax(170px,210px) 104px;
  gap:12px
}
.split-allocation-column-headings {
  align-items:end;
  padding:0 14px;
  color:var(--muted);
  font-size:12px;
  font-weight:800;
  letter-spacing:.04em;
  text-transform:uppercase
}
.split-allocation-list {
  display:grid;
  gap:10px
}
.split-allocation-row {
  align-items:start;
  padding:14px;
  border:1px solid var(--border);
  border-radius:12px;
  background:var(--surface-2,#f8faf9)
}
.split-allocation-index {
  align-self:start;
  display:grid;
  place-items:center;
  width:30px;
  height:42px;
  border-radius:10px;
  background:var(--brand-soft,#e8f5f2);
  color:var(--brand);
  font-size:13px;
  font-weight:800
}
.split-allocation-row .field-group {
  min-width:0;
  margin:0
}
.split-allocation-row .field-group>label {
  display:none
}
.split-allocation-row input,
.split-allocation-row select {
  width:100%;
  min-width:0;
  box-sizing:border-box
}
.split-suggestion-meta {
  display:block;
  margin-top:6px;
  color:var(--muted);
  font-size:12px;
  line-height:1.35
}
.split-suggestion-meta strong {
  color:var(--brand)
}
.split-allocation-remove {
  display:flex;
  align-items:flex-start;
  justify-content:flex-end;
  min-height:42px
}
.split-allocation-remove .small-button {
  width:100%;
  justify-content:center
}
.split-allocation-summary {
  display:grid;
  grid-template-columns:repeat(3,minmax(140px,.55fr)) minmax(240px,1.35fr);
  gap:12px;
  padding:14px;
  border:1px solid var(--border);
  border-radius:12px;
  background:var(--surface)
}
.split-allocation-summary>div {
  min-width:0
}
.split-allocation-summary strong {
  display:block;
  margin-top:4px;
  color:var(--text-strong);
  font-size:18px
}
.split-allocation-summary>div.is-balanced strong {
  color:var(--brand)
}
.split-allocation-status {
  align-self:center;
  padding:10px 12px;
  border-radius:10px;
  background:var(--warning-soft,#fff7df);
  color:var(--text);
  font-weight:700;
  line-height:1.4
}
.split-allocation-status.is-balanced {
  background:var(--brand-soft,#e8f5f2);
  color:var(--brand)
}
.split-allocation-status.is-over {
  background:var(--danger-soft,#fff0f0);
  color:var(--danger,#a52a2a)
}
.split-review-note {
  margin:0
}
.split-allocation-actions {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:18px;
  padding-top:2px
}
.split-allocation-actions p {
  max-width:680px;
  margin:0;
  color:var(--muted);
  font-size:13px;
  line-height:1.5
}
.split-allocation-actions .button {
  flex:0 0 auto
}
.reconciliation-suggestions-card {
  margin-top:18px
}
.reconciliation-suggestions-card .card-header p {
  margin:4px 0 0;
  color:var(--muted)
}
.reconciliation-review-message {
  padding:20px 22px
}
.reconciliation-review-message p {
  margin:0
}

@media (max-width:1050px) {
  .reconciliation-transaction-strip {
    grid-template-columns:repeat(3,minmax(0,1fr))
  }
  .reconciliation-transaction-strip>div:nth-child(3) {
    border-right:0
  }
  .reconciliation-transaction-strip>div:nth-child(n+4) {
    border-top:1px solid var(--border)
  }
  .reconciliation-transaction-narration {
    grid-column:span 2
  }
  .split-allocation-summary {
    grid-template-columns:repeat(3,minmax(0,1fr))
  }
  .split-allocation-status {
    grid-column:1/-1
  }
}

@media (max-width:760px) {
  .reconciliation-review-header,
  .split-allocation-toolbar,
  .split-allocation-actions {
    align-items:stretch;
    flex-direction:column
  }
  .split-transaction-total {
    width:100%;
    box-sizing:border-box;
    text-align:left
  }
  .reconciliation-transaction-strip {
    grid-template-columns:repeat(2,minmax(0,1fr));
    margin:0 16px
  }
  .reconciliation-transaction-strip>div,
  .reconciliation-transaction-strip>div:nth-child(3) {
    border-right:1px solid var(--border);
    border-top:1px solid var(--border)
  }
  .reconciliation-transaction-strip>div:nth-child(-n+2) {
    border-top:0
  }
  .reconciliation-transaction-strip>div:nth-child(even) {
    border-right:0
  }
  .reconciliation-transaction-narration {
    grid-column:1/-1;
    border-right:0
  }
  .split-allocation-column-headings {
    display:none
  }
  .split-allocation-row {
    grid-template-columns:32px minmax(0,1fr)
  }
  .split-allocation-row .field-group>label {
    display:block
  }
  .split-allocation-property,
  .split-allocation-amount,
  .split-allocation-remove {
    grid-column:2
  }
  .split-allocation-remove {
    justify-content:stretch;
    min-height:0
  }
  .split-allocation-summary {
    grid-template-columns:repeat(2,minmax(0,1fr))
  }
  .split-allocation-summary>div:nth-child(3),
  .split-allocation-status {
    grid-column:1/-1
  }
  .split-allocation-actions .button,
  .split-allocation-toolbar .small-button {
    width:100%;
    justify-content:center
  }
}

@media (max-width:480px) {
  .reconciliation-transaction-strip {
    grid-template-columns:1fr
  }
  .reconciliation-transaction-strip>div,
  .reconciliation-transaction-strip>div:nth-child(even),
  .reconciliation-transaction-strip>div:nth-child(3) {
    grid-column:auto;
    border-right:0;
    border-top:1px solid var(--border)
  }
  .reconciliation-transaction-strip>div:first-child {
    border-top:0
  }
  .split-allocation-form {
    padding:16px
  }
  .split-allocation-summary {
    grid-template-columns:1fr
  }
  .split-allocation-summary>div:nth-child(3),
  .split-allocation-status {
    grid-column:auto
  }
}
/* ===== END pages/payments.css ===== */

/* ===== BEGIN pages/reconciliation.css ===== */
/*
 * ARBS stylesheet: pages/reconciliation.css
 * Purpose: Reconciliation and Equity statement intake workflow refinements.
 * Architecture: Page-scoped rules only; preserves the approved statement-review UI.
 */
/* Equity statement review workflow. Scoped to reconciliation intake only. */
.statement-import-header .staff-eyebrow,
.statement-review-header .staff-eyebrow { margin-bottom: .25rem; }
.statement-flow { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:12px; margin:0 0 1.25rem; }
.statement-flow-step { display:flex; align-items:center; gap:.8rem; min-width:0; padding:.9rem 1rem; border:1px solid var(--border); border-radius:14px; background:var(--surface); }
.statement-flow-step > span { width:32px; height:32px; flex:0 0 32px; display:grid; place-items:center; border-radius:50%; border:1px solid var(--border); font-weight:800; color:var(--muted); background:var(--surface-soft); }
.statement-flow-step strong,.statement-flow-step small { display:block; }
.statement-flow-step small { color:var(--muted); margin-top:2px; }
.statement-flow-step.is-active { border-color:color-mix(in srgb,var(--brand) 38%,var(--border)); box-shadow:0 0 0 3px color-mix(in srgb,var(--brand) 8%,transparent); }
.statement-flow-step.is-active > span,.statement-flow-step.is-complete > span { background:var(--brand); border-color:var(--brand); color:#fff; }
.statement-import-grid { display:grid; grid-template-columns:minmax(0,1.55fr) minmax(280px,.85fr); gap:1.25rem; align-items:start; }
.statement-upload-form .field-group + .field-group { margin-top:1rem; }
.statement-upload-form input[type="file"] { padding:.7rem; background:var(--surface-soft); border:1px dashed var(--border); }
.statement-upload-form input[type="password"] { max-width:340px; }
.field-help { display:block; margin-top:.4rem; color:var(--muted); line-height:1.45; }
.statement-upload-form .field-error { display:block; margin-top:.35rem; color:var(--danger); font-weight:700; }
.statement-form-actions { margin-top:1.35rem; display:flex; justify-content:flex-end; gap:.65rem; flex-wrap:wrap; }
.statement-security-card { position:sticky; top:1rem; }
.statement-security-icon { width:40px; height:40px; display:grid; place-items:center; border-radius:12px; background:color-mix(in srgb,var(--brand) 12%,transparent); color:var(--brand); font-weight:900; margin-bottom:1rem; }
.statement-security-card h3 { margin:.2rem 0 1rem; }
.statement-control-list { display:grid; gap:1rem; }
.statement-control-list > div { padding-top:1rem; border-top:1px solid var(--border); }
.statement-control-list > div:first-child { padding-top:0; border-top:0; }
.statement-control-list p { margin:.25rem 0 0; color:var(--muted); line-height:1.5; }
.statement-review-summary { display:grid; grid-template-columns:repeat(5,minmax(0,1fr)); gap:10px; margin-bottom:1rem; }
.statement-review-summary article { min-width:0; padding:1rem; border:1px solid var(--border); border-radius:14px; background:var(--surface); box-shadow:var(--shadow-sm); }
.statement-review-summary span,.statement-review-summary small { display:block; color:var(--muted); }
.statement-review-summary strong { display:block; margin:.3rem 0; font-size:1.15rem; overflow-wrap:anywhere; }
.statement-review-notice { margin-bottom:1rem; border-left:4px solid var(--brand); }
.statement-review-card { overflow:hidden; }
.statement-select-all { display:flex; align-items:center; gap:.5rem; font-weight:700; white-space:nowrap; }
.statement-check-column { width:44px; text-align:center; }
.statement-review-table input[type="checkbox"],.statement-select-all input[type="checkbox"] { width:17px; height:17px; accent-color:var(--brand); }
.statement-review-table .statement-narration { min-width:260px; max-width:480px; white-space:normal; overflow-wrap:anywhere; color:var(--muted); line-height:1.45; }
.statement-review-footer { display:flex; justify-content:space-between; align-items:center; gap:1rem; padding:1rem 1.35rem; border-top:1px solid var(--border); background:var(--surface-soft); }
@media (max-width:1100px) { .statement-review-summary { grid-template-columns:repeat(3,minmax(0,1fr)); } }
@media (max-width:820px) { .statement-import-grid { grid-template-columns:1fr; } .statement-security-card { position:static; } .statement-flow { grid-template-columns:1fr; } .statement-review-summary { grid-template-columns:repeat(2,minmax(0,1fr)); } .statement-review-footer { align-items:flex-start; flex-direction:column; } }
@media (max-width:520px) { .statement-review-summary { grid-template-columns:1fr; } .statement-form-actions .button,.statement-review-footer .button { width:100%; text-align:center; } }
/* ===== END pages/reconciliation.css ===== */

/* ===== BEGIN pages/analytics.css ===== */
/*
 * ARBS stylesheet: pages/analytics.css
 * Purpose: Analytics filters, metrics and chart-card grids.
 * Architecture: Page layer; analytics-only selectors.
 */

.analytics-summary-grid {
   display:grid;
   grid-template-columns:repeat(3,minmax(0,1fr));
   gap:1.1rem
}
 .analytics-summary-card {
   display:grid;
   grid-template-columns:52px minmax(0,1fr);
   gap:1rem;
   min-width:0;
   min-height:205px;
   padding:1.35rem 1.4rem;
   border:1px solid var(--border);
   border-radius:16px;
   background:var(--surface);
   box-shadow:var(--shadow-sm);
   color:inherit;
   text-decoration:none;
   transition:border-color .15s ease,box-shadow .15s ease,transform .15s ease
}
 .analytics-summary-card:hover {
   transform:translateY(-2px);
   border-color:color-mix(in srgb,var(--brand) 34%,var(--border));
   box-shadow:var(--shadow-md)
}
 .analytics-summary-icon {
   display:grid;
   place-items:center;
   width:52px;
   height:52px;
   border-radius:15px;
   background:color-mix(in srgb,var(--brand) 13%,transparent);
   color:var(--brand);
   font-size:1.35rem;
   font-weight:900;
   line-height:1
}
 .analytics-summary-icon--warning {
   background:#fffaeb;
   color:#b54708
}
 .analytics-summary-content {
   display:flex;
   flex-direction:column;
   min-width:0
}
 .analytics-summary-label {
   color:var(--muted);
   font-size:.74rem;
   font-weight:800;
   letter-spacing:.07em;
   text-transform:uppercase
}
 .analytics-summary-content strong {
   margin:.5rem 0 .6rem;
   color:var(--text-strong);
   font-size:1.55rem;
   line-height:1.18;
   overflow-wrap:anywhere
}
 .analytics-summary-content p {
   margin:0;
   color:var(--muted);
   font-size:.9rem;
   line-height:1.58
}
 .analytics-summary-card--financial .analytics-summary-icon {
   background:color-mix(in srgb,#12b76a 14%,transparent);
   color:#039855
}
 @media(max-width:1000px) {
   .analytics-summary-grid {
     grid-template-columns:repeat(2,minmax(0,1fr))
  }

}
 @media(max-width:700px) {
   .analytics-summary-grid {
     grid-template-columns:1fr
  }
   .analytics-summary-card {
     grid-template-columns:46px minmax(0,1fr);
     min-height:0;
     padding:1.1rem
  }
   .analytics-summary-icon {
     width:46px;
     height:46px;
     border-radius:13px;
     font-size:1.2rem
  }

}
 /* Analytics dashboard layout and chart components. */
 .analytics-page-header {
   align-items:center
}
 .analytics-updated {
   display:grid;
   gap:.2rem;
   min-width:170px;
   padding:.75rem 1rem;
   border:1px solid var(--border);
   border-radius:12px;
   background:var(--surface-2);
   text-align:right
}
 .analytics-updated span {
   color:var(--muted);
   font-size:.72rem;
   font-weight:800;
   letter-spacing:.06em;
   text-transform:uppercase
}
 .analytics-updated strong {
   color:var(--text-strong)
}
 .analytics-filter-grid {
   display:grid;
   grid-template-columns:repeat(4,minmax(150px,1fr)) auto;
   gap:1rem;
   align-items:end;
   padding:1.25rem 1.4rem
}
 .analytics-filter-grid .field-group {
   display:flex;
   flex-direction:column;
   gap:.42rem
}
 .analytics-section {
   display:grid;
   gap:1rem
}
 .analytics-section-heading {
   display:flex;
   align-items:flex-end;
   justify-content:space-between;
   gap:1rem
}
 .analytics-section-heading h3 {
   margin:.2rem 0 .3rem;
   color:var(--text-strong);
   font-size:1.2rem
}
 .analytics-section-heading p {
   max-width:850px;
   margin:0;
   color:var(--muted);
   line-height:1.55
}
 .analytics-metric-grid {
   display:grid;
   grid-template-columns:repeat(3,minmax(0,1fr));
   gap:1rem
}
 .analytics-metric-grid--financial {
   grid-template-columns:repeat(3,minmax(0,1fr))
}
 .analytics-metric-card {
   display:flex;
   flex-direction:column;
   min-width:0;
   min-height:190px;
   padding:1.2rem;
   border:1px solid var(--border);
   border-radius:15px;
   background:var(--surface);
   box-shadow:var(--shadow-sm);
   color:inherit;
   text-decoration:none;
   transition:transform .15s ease,border-color .15s ease,box-shadow .15s ease
}
 .analytics-metric-card:hover {
   transform:translateY(-2px);
   border-color:color-mix(in srgb,var(--brand) 35%,var(--border));
   box-shadow:var(--shadow-md)
}
 .analytics-metric-label {
   color:var(--muted);
   font-size:.74rem;
   font-weight:800;
   letter-spacing:.07em;
   text-transform:uppercase
}
 .analytics-metric-card strong {
   margin:.55rem 0;
   color:var(--text-strong);
   font-size:1.7rem;
   line-height:1.15;
   overflow-wrap:anywhere
}
 .analytics-metric-card p {
   margin:0;
   color:var(--muted);
   line-height:1.5
}
 .analytics-metric-link {
   margin-top:auto;
   padding-top:1rem;
   color:var(--brand);
   font-size:.82rem;
   font-weight:800
}
 .analytics-chart-grid {
   display:grid;
   grid-template-columns:repeat(2,minmax(0,1fr));
   gap:1rem
}
 .analytics-chart-grid--three {
   grid-template-columns:repeat(3,minmax(0,1fr))
}
 .analytics-chart-card {
   min-width:0;
   padding:1.2rem;
   border:1px solid var(--border);
   border-radius:15px;
   background:var(--surface);
   box-shadow:var(--shadow-sm)
}
 .analytics-chart-card--wide {
   grid-column:1/-1
}
 .analytics-chart-card__heading {
   min-height:72px;
   margin-bottom:.8rem
}
 .analytics-chart-card__heading h4 {
   margin:0;
   color:var(--text-strong);
   font-size:1.02rem
}
 .analytics-chart-card__heading p {
   margin:.35rem 0 0;
   color:var(--muted);
   font-size:.86rem;
   line-height:1.5
}
 .analytics-chart {
   position:relative;
   min-height:300px
}
 .analytics-chart canvas {
   display:block;
   width:100%;
   height:300px
}
 .analytics-method-note {
   padding:1.1rem 1.25rem;
   border:1px solid color-mix(in srgb,var(--brand) 25%,var(--border));
   border-radius:14px;
   background:var(--brand-soft)
}
 .analytics-method-note strong {
   display:block;
   color:var(--text-strong)
}
 .analytics-method-note p {
   margin:.35rem 0 0;
   color:var(--text);
   line-height:1.55
}
 @media (max-width:1100px) {
   .analytics-filter-grid {
     grid-template-columns:repeat(2,minmax(0,1fr))
  }
   .analytics-filter-grid .staff-filter-actions {
     grid-column:1/-1
  }
   .analytics-chart-grid--three {
     grid-template-columns:repeat(2,minmax(0,1fr))
  }
   .analytics-chart-grid--three .analytics-chart-card:last-child {
     grid-column:1/-1
  }

}
 @media (max-width:900px) {
   .analytics-metric-grid {
     grid-template-columns:repeat(2,minmax(0,1fr))
  }

}
 @media (max-width:700px) {
   .analytics-metric-grid, .analytics-chart-grid, .analytics-chart-grid--three {
     grid-template-columns:1fr
  }
   .analytics-chart-grid--three .analytics-chart-card:last-child, .analytics-chart-card--wide {
     grid-column:auto
  }
   .analytics-filter-grid {
     grid-template-columns:1fr
  }
   .analytics-filter-grid .staff-filter-actions {
     grid-column:auto;
     align-items:stretch;
     flex-direction:column
  }
   .analytics-updated {
     text-align:left
  }
   .analytics-chart canvas {
     height:260px
  }

}

/* Analytics phone layout. */
@media (max-width: 760px) {
  .analytics-summary-grid,
  .analytics-filter-grid,
  .analytics-metric-grid,
  .analytics-metric-grid--financial,
  .analytics-chart-grid,
  .analytics-chart-grid--three { grid-template-columns: minmax(0, 1fr); }
  .analytics-summary-grid > *,
  .analytics-filter-grid > *,
  .analytics-metric-grid > *,
  .analytics-chart-grid > * { min-width: 0; }
}
/* ===== END pages/analytics.css ===== */

/* ===== BEGIN pages/professionals.css ===== */
/*
 * ARBS stylesheet: pages/professionals.css
 * Purpose: Recommended professionals directory, profiles and review forms.
 * Architecture: Page layer; professionals-only selectors.
 */

.category-tags {
   display: flex;
   flex-wrap: wrap;
   gap: 5px;

}

.category-tags span {
   padding: 4px 7px;
   border-radius: 999px;
   background: var(--surface-3);
   color: var(--muted);
   font-size: 11px;

}


.professional-card-top,
.review-heading {
  display: flex;
  align-items: flex-start;
  gap: 11px;
}

.professional-avatar {
  flex: none;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: var(--brand-soft);
  color: var(--brand-deep);
  font-weight: 800;
}
 /* Recommended professionals and analytics coordinated UI */
 .professionals-header {
   align-items:center
}
 .professionals-guidance {
   margin-bottom:0
}
 .professionals-filter-grid {
   display:grid;
   grid-template-columns:minmax(260px,2fr) minmax(190px,1fr) minmax(170px,.8fr) auto;
   gap:1rem;
   align-items:end;
   padding:1.25rem 1.4rem
}
 .professionals-filter-grid .field-group {
   display:flex;
   flex-direction:column;
   gap:.42rem;
   min-width:0
}
 .directory-count {
   display:inline-flex;
   align-items:center;
   min-height:34px;
   padding:.35rem .7rem;
   border:1px solid var(--border);
   border-radius:999px;
   background:var(--surface-2);
   color:var(--muted);
   font-size:.78rem;
   font-weight:800;
   white-space:nowrap
}
 .professional-directory-grid {
   display:grid;
   grid-template-columns:repeat(3,minmax(0,1fr));
   gap:1rem
}
 .professional-directory-card {
   display:flex;
   flex-direction:column;
   min-width:0;
   padding:1.2rem;
   border:1px solid var(--border);
   border-radius:15px;
   background:var(--surface);
   box-shadow:var(--shadow-sm)
}
 .professional-directory-card__top {
   display:flex;
   align-items:flex-start;
   gap:.85rem
}
 .professional-directory-card__identity {
   min-width:0;
   flex:1
}
 .professional-title-row {
   display:flex;
   align-items:flex-start;
   justify-content:space-between;
   gap:.65rem
}
 .professional-title-row h3 {
   min-width:0;
   margin:0;
   color:var(--text-strong);
   font-size:1.05rem;
   overflow-wrap:anywhere
}
 .professional-directory-card__identity p {
   margin:.25rem 0 0;
   color:var(--muted);
   font-size:.86rem
}
 .professional-directory-card .category-tags {
   margin-top:1rem
}
 .professional-rating-row {
   display:flex;
   align-items:flex-start;
   justify-content:space-between;
   gap:1rem;
   margin-top:1rem;
   padding-top:.9rem;
   border-top:1px solid var(--border)
}
 .professional-rating-row>div {
   display:grid;
   gap:.15rem
}
 .professional-rating-row strong {
   color:var(--text-strong)
}
 .professional-rating-row small, .professional-rating-row .service-area {
   color:var(--muted);
   font-size:.77rem
}
 .professional-rating-row .service-area {
   text-align:right
}
 .provider-summary {
   margin:1rem 0;
   color:var(--text);
   line-height:1.55
}
 .muted-copy {
   color:var(--muted)
}
 .professional-card-actions {
   display:flex;
   align-items:center;
   gap:.65rem;
   margin-top:auto;
   padding-top:.2rem
}
 .professional-card-actions .button {
   flex:1;
   min-width:0;
   justify-content:center
}
 .professional-empty {
   grid-column:1/-1;
   padding:2.25rem
}
 .professional-detail-layout {
   display:grid;
   grid-template-columns:minmax(0,1.6fr) minmax(280px,.55fr);
   gap:1.25rem;
   align-items:start
}
 .provider-profile-hero {
   display:grid;
   grid-template-columns:72px minmax(0,1fr);
   gap:1rem;
   align-items:center;
   padding:1.4rem;
   border-bottom:1px solid var(--border);
   background:var(--surface-2)
}
 .professional-avatar--large {
   width:72px;
   height:72px;
   border-radius:18px;
   font-size:1.35rem
}
 .provider-profile-hero h3 {
   font-size:1.35rem
}
 .provider-profile-hero p {
   margin:.3rem 0;
   color:var(--muted)
}
 .provider-profile-body {
   display:grid;
   gap:1.4rem
}
 .provider-description-block p {
   margin:.45rem 0 0;
   line-height:1.65
}
 .professional-contact-grid {
   display:grid;
   grid-template-columns:repeat(2,minmax(0,1fr));
   gap:1rem;
   margin:0
}
 .professional-contact-grid>div {
   min-width:0;
   padding:1rem;
   border:1px solid var(--border);
   border-radius:12px;
   background:var(--surface-2)
}
 .professional-contact-grid dt {
   color:var(--muted);
   font-size:.72rem;
   font-weight:800;
   letter-spacing:.06em;
   text-transform:uppercase
}
 .professional-contact-grid dd {
   margin:.3rem 0 0;
   overflow-wrap:anywhere
}
 .professional-score-body {
   display:grid;
   justify-items:center;
   gap:.35rem;
   text-align:center
}
 .professional-score-body p {
   margin:.4rem 0 0;
   color:var(--muted)
}
 .professional-checklist {
   display:grid;
   gap:.8rem;
   margin:0;
   padding-left:1.2rem
}
 .professional-checklist li {
   padding-left:.25rem;
   color:var(--text);
   line-height:1.5
}
 .professional-review-list {
   display:grid;
   gap:1rem
}
 .professional-review-card {
   padding:1rem;
   border:1px solid var(--border);
   border-radius:13px;
   background:var(--surface-2)
}
 .professional-review-card h4 {
   margin:.9rem 0 .4rem
}
 .professional-review-card>p {
   margin:.4rem 0;
   line-height:1.6
}
 .professional-form-layout {
   display:grid;
   grid-template-columns:minmax(0,1.5fr) minmax(280px,.5fr);
   gap:1.25rem;
   align-items:start
}
 .professional-form .field-help {
   margin:.35rem 0 0;
   color:var(--muted);
   font-size:.8rem
}
 .professional-form input, .professional-form select, .professional-form textarea {
   width:100%;
   box-sizing:border-box
}
 @media (max-width:1100px) {
   .professional-directory-grid {
     grid-template-columns:repeat(2,minmax(0,1fr))
  }

}
 @media (max-width:900px) {
   .professionals-filter-grid {
     grid-template-columns:repeat(2,minmax(0,1fr))
  }
   .professionals-filter-grid .staff-filter-actions {
     grid-column:1/-1
  }
   .professional-detail-layout, .professional-form-layout {
     grid-template-columns:1fr
  }

}
 @media (max-width:700px) {
   .professional-directory-grid {
     grid-template-columns:1fr
  }
   .professionals-filter-grid {
     grid-template-columns:1fr
  }
   .professionals-filter-grid .staff-filter-actions {
     grid-column:auto;
     align-items:stretch;
     flex-direction:column
  }
   .professional-card-actions {
     align-items:stretch;
     flex-direction:column
  }
   .professional-card-actions .button {
     width:100%
  }
   .professional-contact-grid {
     grid-template-columns:1fr
  }
   .provider-profile-hero {
     grid-template-columns:54px minmax(0,1fr);
     padding:1rem
  }
   .professional-avatar--large {
     width:54px;
     height:54px;
     border-radius:15px
  }

}
 /* Professional recommendation workflow */
 .professional-recommendation-form {
   display:grid;
   gap:1.25rem
}
 .professional-recommendation-layout {
   display:grid;
   grid-template-columns:minmax(0,1.55fr) minmax(290px,.45fr);
   gap:1.25rem;
   align-items:start
}
 .professional-recommendation-main {
   display:grid;
   gap:1.25rem;
   min-width:0
}
 .professional-recommendation-aside {
   min-width:0
}
 .professional-form-section {
   overflow:hidden
}
 .professional-section-grid {
   display:grid;
   grid-template-columns:repeat(2,minmax(0,1fr));
   gap:1.15rem 1.25rem
}
 .professional-section-grid .field-group {
   display:flex;
   flex-direction:column;
   min-width:0;
   gap:.42rem
}
 .professional-section-grid .field-group>label {
   color:var(--text);
   font-size:.82rem;
   font-weight:800
}
 .professional-section-grid input, .professional-section-grid select, .professional-section-grid textarea {
   width:100%;
   box-sizing:border-box
}
 .professional-section-grid input, .professional-section-grid select {
   height:46px;
   min-height:46px
}
 .professional-section-grid textarea {
   min-height:132px;
   resize:vertical
}
 .professional-section-grid .span-full {
   grid-column:1/-1
}
 .professional-select-shell {
   position:relative
}
 select.professional-category-select {
   height:46px;
   min-height:46px;
   padding-right:2.5rem
}
 .professional-section-grid .field-help {
   margin:.1rem 0 0;
   color:var(--muted);
   font-size:.78rem;
   line-height:1.45
}
 .professional-section-grid .errorlist {
   margin:.15rem 0 0;
   padding-left:1.15rem;
   color:#b42318;
   font-size:.8rem
}
 .professional-guidance-stack>div {
   padding-block:1rem
}
 .professional-submit-card {
   display:flex;
   align-items:center;
   justify-content:space-between;
   gap:1.5rem;
   padding:1.25rem 1.4rem;
   border:1px solid color-mix(in srgb,var(--brand) 30%,var(--border));
   border-radius:16px;
   background:color-mix(in srgb,var(--brand) 6%,var(--surface));
   box-shadow:var(--shadow-sm)
}
 .professional-submit-copy {
   display:flex;
   align-items:center;
   gap:1rem;
   min-width:0
}
 .professional-submit-icon {
   display:grid;
   place-items:center;
   flex:0 0 48px;
   width:48px;
   height:48px;
   border-radius:14px;
   background:var(--brand);
   color:#fff;
   font-size:1.2rem;
   font-weight:900
}
 .professional-submit-copy h3 {
   margin:.15rem 0 .25rem;
   color:var(--text-strong);
   font-size:1.05rem
}
 .professional-submit-copy p {
   margin:0;
   color:var(--muted);
   line-height:1.5
}
 .professional-submit-actions {
   display:flex;
   align-items:center;
   gap:.7rem;
   flex:0 0 auto
}
 .professional-submit-actions .button {
   white-space:nowrap
}
 @media (max-width:900px) {
   .professional-recommendation-layout {
     grid-template-columns:1fr
  }
   .professional-recommendation-aside .sticky-card {
     position:static
  }

}
 @media (max-width:700px) {
   .professional-section-grid {
     grid-template-columns:1fr
  }
   .professional-section-grid .span-full {
     grid-column:auto
  }
   .professional-submit-card {
     align-items:stretch;
     flex-direction:column
  }
   .professional-submit-copy {
     align-items:flex-start
  }
   .professional-submit-actions {
     align-items:stretch;
     flex-direction:column-reverse
  }
   .professional-submit-actions .button {
     width:100%;
     justify-content:center
  }

}

@media (max-width: 760px) {
  .professional-directory-grid,
  .professionals-filter-grid,
  .professional-detail-layout,
  .professional-form-layout,
  .professional-recommendation-layout,
  .professional-section-grid,
  .professional-contact-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .professional-directory-grid > *,
  .professional-detail-layout > *,
  .professional-form-layout > *,
  .professional-recommendation-layout > * {
    min-width: 0;
  }
}
/* ===== END pages/professionals.css ===== */

/* ===== BEGIN pages/map.css ===== */
/*
 * ARBS stylesheet: pages/map.css
 * Purpose: Interactive masterplan map and property information panel.
 * Architecture: Page layer; map-only selectors.
 */

.map-page {
   min-width: 0;

}
 .map-toolbar {
   display: flex;
   align-items: flex-end;
   justify-content: space-between;
   gap: 18px;
   margin-bottom: 16px;
   padding: 17px 18px;

}
 .map-toolbar h2 {
   margin: 0 0 4px;
   color: var(--text-strong);
   font-size: 22px;

}
 .map-toolbar p {
   margin: 0;
   color: var(--muted);

}
 .map-controls {
   display: grid;
   grid-template-columns: minmax(135px,180px) auto 42px 42px auto;
   align-items: center;
   gap: 8px;
   flex: none;

}
 .map-controls > input:not([type="checkbox"]):not([type="radio"]) {
   min-height: 42px ;

}
 .masterplan-layout {
   display: grid;
   grid-template-columns: minmax(0,1fr) minmax(380px,430px);
   gap: 20px;
   align-items: start;

}
 .masterplan-card {
   position: relative;
   min-width: 0;
   overflow: hidden;

}
 .map-scroll {
   width: 100%;
   height: min(72vh,820px);
   overflow: auto;
   background: #e8edeb;
   overscroll-behavior: contain;
   cursor: grab;
   touch-action: pan-x pan-y;
   user-select: none;

}
 .map-scroll.is-dragging {
   cursor: grabbing;

}
 .map-scroll.is-dragging .plot-hotspot {
   pointer-events: none;

}
 .dark .map-scroll {
   background: #172335;

}
 .map-stage {
   position: relative;

}
 .masterplan-svg {
   display: block;

}
 .plot-hotspot {
   fill: rgba(15,138,120,.03);
   stroke: rgba(15,138,120,.42);
   stroke-width: 2;
   vector-effect: non-scaling-stroke;
   cursor: pointer;
   transition: fill .12s, stroke .12s;

}
 .plot-hotspot:hover, .plot-hotspot:focus {
   fill: rgba(20,184,166,.28);
   stroke: #0f8a78;
   outline: none;

}
 .plot-hotspot.selected {
   fill: rgba(245,158,11,.34);
   stroke: #d97706;
   stroke-width: 3;

}
 .plot-hotspot.approximate {
   stroke-dasharray: 5 4;

}
 .map-tooltip {
   position: fixed;
   z-index: 100;
   width: 190px;
   display: grid;
   gap: 2px;
   padding: 10px 12px;
   border: 1px solid var(--border);
   border-radius: 9px;
   background: var(--surface);
   color: var(--text);
   box-shadow: var(--shadow-lg);
   pointer-events: none;

}
 .map-tooltip strong {
   color: var(--text-strong);

}
 .map-tooltip span, .map-tooltip small {
   color: var(--muted);

}
 .map-source-note {
   margin: 0;
   padding: 10px 13px;
   border-top: 1px solid var(--border);
   color: var(--muted);
   font-size: 11px;

}
 .plot-detail-panel {
   min-height: 280px;
   max-height: calc(100vh - var(--topbar-height) - 48px);
   position: sticky;
   top: calc(var(--topbar-height) + 16px);
   overflow: auto;

}
 .plot-detail-header {
   padding: 18px;
   border-bottom: 1px solid var(--border);

}
 .plot-detail-panel .definition-list, .plot-detail-panel .detail-list {
   padding: 14px 18px;

}
 .compact-list {
   display: grid;
   gap: 10px;
   margin: 10px 0 22px;
   padding-left: 20px;

}
 .compact-list li {
   color: var(--text);
   line-height: 1.4;

}
 .compact-list li strong {
   color: var(--text-strong);

}
 .compact-list li .relationship-role {
   display: inline-block;
   margin-left: 8px;
   color: var(--muted);
   font-weight: 500;

}
 /* Interactive masterplan property workspace */
 .map-property-detail {
   min-width:0
}
 .map-property-hero {
   display:grid;
   grid-template-columns:52px minmax(0,1fr) auto;
   gap:13px;
   align-items:center;
   padding:20px;
   border-bottom:1px solid var(--border);
   background:linear-gradient(180deg,var(--surface),var(--surface-2))
}
 .map-property-icon {
   display:grid;
   place-items:center;
   width:52px;
   height:52px;
   border-radius:14px;
   background:var(--brand-soft);
   color:var(--brand);
   font-size:22px;
   font-weight:800
}
 .map-property-title {
   min-width:0
}
 .map-property-title .eyebrow {
   margin-bottom:3px
}
 .map-property-title h2 {
   margin:0;
   color:var(--text-strong);
   font-size:24px;
   letter-spacing:-.025em
}
 .map-property-title p:not(.eyebrow) {
   margin:4px 0 0;
   color:var(--muted);
   font-size:12px;
   line-height:1.4;
   overflow-wrap:anywhere
}
 .map-property-hero .status-badge {
   align-self:start;
   max-width:120px;
   overflow:hidden;
   text-overflow:ellipsis
}
 .map-property-section {
   padding:20px;
   border-bottom:1px solid var(--border)
}
 .map-property-section:last-child {
   border-bottom:0
}
 .map-property-section--staff {
   background:color-mix(in srgb,var(--brand) 3%,var(--surface))
}
 .map-property-section-heading {
   display:grid;
   grid-template-columns:38px minmax(0,1fr);
   gap:11px;
   align-items:start;
   margin-bottom:15px
}
 .map-property-section-heading>span {
   display:grid;
   place-items:center;
   width:38px;
   height:38px;
   border-radius:10px;
   background:var(--brand-soft);
   color:var(--brand);
   font-size:14px;
   font-weight:900
}
 .map-property-section-heading h3 {
   margin:1px 0 3px;
   color:var(--text-strong);
   font-size:15px
}
 .map-property-section-heading p {
   margin:0;
   color:var(--muted);
   font-size:12px;
   line-height:1.45
}
 .map-property-grid {
   display:grid;
   grid-template-columns:repeat(2,minmax(0,1fr));
   gap:10px;
   margin:0
}
 .map-property-grid>div {
   min-width:0;
   padding:12px 13px;
   border:1px solid var(--border);
   border-radius:10px;
   background:var(--surface)
}
 .map-property-grid .span-full {
   grid-column:1/-1
}
 .map-property-grid dt {
   margin:0 0 5px;
   color:var(--muted);
   font-size:10px;
   font-weight:800;
   letter-spacing:.06em;
   text-transform:uppercase
}
 .map-property-grid dd {
   min-width:0;
   margin:0;
   color:var(--text-strong);
   font-size:13px;
   font-weight:650;
   line-height:1.45;
   overflow-wrap:anywhere
}
 .map-property-balance {
   border-color:var(--success-border);
   background:var(--success-soft)
}
 .map-property-balance dd {
   color:var(--success);
   font-size:18px
}
 .map-property-list {
   display:grid;
   gap:9px
}
 .map-property-list-row {
   display:flex;
   align-items:center;
   justify-content:space-between;
   gap:12px;
   padding:12px 13px;
   border:1px solid var(--border);
   border-radius:10px;
   background:var(--surface)
}
 .map-property-list-row>div {
   min-width:0;
   display:grid;
   gap:3px
}
 .map-property-list-row strong {
   color:var(--text-strong);
   overflow-wrap:anywhere
}
 .map-property-list-row small {
   color:var(--muted)
}
 .map-property-list-row>b {
   flex:none;
   color:var(--text-strong);
   font-size:12px;
   white-space:nowrap
}
 .map-property-empty {
   padding:15px;
   border:1px dashed var(--border-strong);
   border-radius:10px;
   color:var(--muted);
   text-align:center;
   font-size:12px
}
 .map-property-privacy {
   display:grid;
   grid-template-columns:36px minmax(0,1fr);
   gap:11px;
   margin:16px 20px 20px;
   padding:14px;
   border:1px solid var(--info-border);
   border-radius:11px;
   background:var(--info-soft);
   color:var(--info)
}
 .map-property-privacy>span {
   font-size:18px
}
 .map-property-privacy strong {
   display:block
}
 .map-property-privacy p {
   margin:4px 0 0;
   color:var(--info);
   font-size:12px;
   line-height:1.5
}
 @media(max-width:1180px) {
   .masterplan-layout {
     grid-template-columns:1fr
  }
   .plot-detail-panel {
     position:static;
     max-height:none
  }

}
@media (max-width: 900px) {
  .map-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .map-controls {
    width: 100%;
  }
}
 @media(max-width:560px) {
   .map-property-hero {
     grid-template-columns:44px minmax(0,1fr);
     padding:16px
  }
   .map-property-icon {
     width:44px;
     height:44px;
     border-radius:12px
  }
   .map-property-hero .status-badge {
     grid-column:1/-1;
     justify-self:start
  }
   .map-property-section {
     padding:16px
  }
   .map-property-grid {
     grid-template-columns:1fr
  }
   .map-property-grid .span-full {
     grid-column:auto
  }
   .map-property-list-row {
     align-items:flex-start;
     flex-direction:column
  }
   .map-property-privacy {
     margin:14px 16px 16px
  }

}

@media (max-width: 760px) {
  .map-controls {
    display: flex;
    align-items: stretch;
    flex-wrap: wrap;
  }

  .map-controls > input:not([type="checkbox"]):not([type="radio"]) {
    flex: 1 1 100%;
  }

  .map-controls > .button {
    flex: 1 1 120px;
  }

  .map-controls > .icon-button {
    flex: 0 0 42px;
  }

  .masterplan-layout,
  .map-property-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .masterplan-layout > *,
  .map-property-grid > * {
    min-width: 0;
  }
}
/* ===== END pages/map.css ===== */

/* ===== BEGIN pages/profile.css ===== */
/*
 * ARBS stylesheet: pages/profile.css
 * Purpose: My Profile account overview, security and phone-number management.
 * Architecture: Page layer; profile-only selectors.
 */

.profile-page {
   display:grid;
   gap:20px
}
 .profile-overview-card {
   display:grid;
   grid-template-columns:64px minmax(0,1fr) auto;
   gap:18px;
   align-items:center;
   padding:22px 24px
}
 .profile-overview-icon {
   display:grid;
   place-items:center;
   width:64px;
   height:64px;
   border-radius:18px;
   background:var(--brand-soft);
   color:var(--brand-deep);
   font-size:24px;
   font-weight:900;
   text-transform:uppercase
}
 .profile-overview-copy {
   min-width:0
}
 .profile-overview-copy h2 {
   margin:3px 0 5px;
   color:var(--text-strong);
   font-size:25px;
   letter-spacing:-.025em
}
 .profile-overview-copy p {
   margin:0;
   color:var(--muted);
   line-height:1.5
}
 .profile-eyebrow {
   display:block;
   color:var(--brand-deep);
   font-size:11px;
   font-weight:900;
   letter-spacing:.09em;
   text-transform:uppercase
}
 .profile-overview-meta {
   display:grid;
   gap:4px;
   min-width:170px;
   padding:13px 15px;
   border:1px solid var(--border);
   border-radius:12px;
   background:var(--surface-2)
}
 .profile-overview-meta span {
   color:var(--muted);
   font-size:12px;
   font-weight:700
}
 .profile-overview-meta strong {
   color:var(--text-strong)
}
 .profile-primary-grid {
   display:grid;
   grid-template-columns:minmax(0,1.55fr) minmax(320px,.7fr);
   gap:20px;
   align-items:start
}
 .profile-details-card,.profile-security-card,.profile-phone-card {
   min-width:0;
   overflow:hidden
}
 .profile-section-heading {
   min-height:94px;
   box-sizing:border-box;
   align-items:center
}
 .profile-section-heading h3 {
   margin:3px 0 4px
}
 .profile-section-heading p {
   max-width:720px
}
 .profile-details-form {
   padding:22px 24px 24px
}
 .profile-fields-grid {
   gap:20px 22px
}
 .profile-security-list {
   display:grid;
   padding:8px 22px 14px
}
 .profile-security-item {
   display:grid;
   grid-template-columns:38px minmax(0,1fr) auto;
   gap:12px;
   align-items:center;
   padding:16px 0;
   border-bottom:1px solid var(--border)
}
 .profile-security-item:last-child {
   border-bottom:0
}
 .profile-security-icon {
   display:grid;
   place-items:center;
   width:36px;
   height:36px;
   border-radius:10px;
   background:var(--brand-soft);
   color:var(--brand-deep);
   font-size:13px;
   font-weight:900
}
 .profile-security-item strong {
   display:block;
   color:var(--text-strong)
}
 .profile-security-item p {
   margin:3px 0 0;
   color:var(--muted);
   font-size:12px;
   line-height:1.45
}
 .profile-security-item>.button,.profile-security-item>.badge {
   justify-self:end;
   white-space:nowrap
}
 .profile-phone-heading {
   align-items:center
}
 .profile-phone-heading>.button {
   flex:0 0 auto;
   white-space:nowrap
}
 .profile-phone-list {
   display:grid;
   padding:4px 22px 10px
}
 .profile-phone-row {
   display:grid;
   grid-template-columns:minmax(0,1fr) auto minmax(146px,auto);
   gap:18px;
   align-items:center;
   padding:17px 2px;
   border-bottom:1px solid var(--border)
}
 .profile-phone-row:last-child {
   border-bottom:0
}
 .profile-phone-main {
   display:grid;
   gap:7px;
   min-width:0
}
 .profile-phone-number-line {
   display:flex;
   align-items:center;
   gap:9px;
   flex-wrap:wrap
}
 .profile-phone-number-line strong {
   color:var(--text-strong);
   font-size:15px;
   overflow-wrap:anywhere
}
 .profile-phone-meta {
   display:flex;
   gap:8px;
   align-items:center;
   flex-wrap:wrap
}
 .profile-phone-meta span {
   display:inline-flex;
   align-items:center;
   color:var(--muted);
   font-size:12px
}
 .profile-phone-meta span+span:before {
   content:"•";
   margin-right:8px;
   color:var(--muted-2)
}
 .profile-phone-verification {
   justify-self:end
}
 .profile-phone-actions {
   display:flex;
   align-items:center;
   justify-content:flex-end;
   gap:8px;
   min-width:146px
}
 .profile-phone-actions form {
   margin:0
}
 .profile-phone-actions .small-button {
   min-width:66px;
   justify-content:center
}
 .profile-phone-empty {
   display:grid;
   justify-items:center;
   gap:8px;
   padding:38px 24px;
   text-align:center
}
 .profile-phone-empty-icon {
   display:grid;
   place-items:center;
   width:48px;
   height:48px;
   border-radius:14px;
   background:var(--brand-soft);
   color:var(--brand-deep);
   font-size:20px
}
 .profile-phone-empty strong {
   color:var(--text-strong);
   font-size:16px
}
 .profile-phone-empty p {
   max-width:520px;
   margin:0 0 8px;
   color:var(--muted);
   line-height:1.5
}
 .profile-save-actions {
   width:100%;
   box-sizing:border-box;
   justify-content:space-between
}
 .profile-save-note {
   color:var(--muted);
   font-size:12px
}
 .profile-save-actions .button {
   min-width:126px
}
 @media(max-width:1050px) {
   .profile-primary-grid {
     grid-template-columns:1fr
  }
   .profile-security-list {
     grid-template-columns:repeat(2,minmax(0,1fr));
     gap:0 20px
  }
   .profile-security-item {
     border-bottom:0
  }
   .profile-security-item:first-child {
     border-right:1px solid var(--border);
     padding-right:20px
  }

}
 @media(max-width:760px) {
   .profile-overview-card {
     grid-template-columns:52px minmax(0,1fr);
     padding:18px
  }
   .profile-overview-icon {
     width:52px;
     height:52px;
     border-radius:14px;
     font-size:20px
  }
   .profile-overview-meta {
     grid-column:1/-1;
     min-width:0
  }
   .profile-security-list {
     grid-template-columns:1fr
  }
   .profile-security-item:first-child {
     border-right:0;
     border-bottom:1px solid var(--border);
     padding-right:0
  }
   .profile-phone-heading {
     align-items:stretch;
     flex-direction:column
  }
   .profile-phone-heading>.button {
     width:100%;
     justify-content:center
  }
   .profile-phone-row {
     grid-template-columns:minmax(0,1fr) auto
  }
   .profile-phone-verification {
     grid-column:2;
     grid-row:1
  }
   .profile-phone-actions {
     grid-column:1/-1;
     justify-content:stretch;
     min-width:0
  }
   .profile-phone-actions>a,.profile-phone-actions form,.profile-phone-actions button {
     flex:1;
     width:100%
  }
   .profile-save-actions {
     align-items:stretch
  }
   .profile-save-note {
     text-align:center
  }
   .profile-save-actions .button {
     width:100%
  }

}
 @media(max-width:480px) {
   .profile-phone-row {
     grid-template-columns:1fr
  }
   .profile-phone-verification {
     grid-column:auto;
     grid-row:auto;
     justify-self:start
  }
   .profile-phone-actions {
     grid-column:auto;
     flex-direction:column
  }
   .profile-section-heading {
     min-height:0
  }

}

/* Profile and contact phone layout. */
@media (max-width: 760px) {
  .profile-primary-grid,
  .profile-security-list { grid-template-columns: minmax(0, 1fr); }
  .profile-primary-grid > *,
  .profile-security-list > * { min-width: 0; }
}
/* ===== END pages/profile.css ===== */

/* ===== BEGIN pages/emergency.css ===== */
/*
 * ARBS stylesheet: pages/emergency.css
 * Purpose: Public emergency directory, safety guidance and contact cards.
 * Architecture: Page layer; emergency-only selectors.
 */

.emergency-page {
   display:grid;
   gap:20px
}
 .public-contact-bar {
   display:flex;
   align-items:center;
   justify-content:space-between;
   gap:12px;
   padding:11px 14px;
   border:1px solid var(--border);
   border-radius:12px;
   background:var(--surface);
   color:var(--muted);
   font-size:13px
}
 .public-contact-bar a {
   color:var(--brand);
   font-weight:800;
   text-decoration:none
}
 .emergency-hero {
   position:relative;
   display:grid;
   grid-template-columns:minmax(0,1fr) 120px;
   gap:28px;
   align-items:center;
   overflow:hidden;
   padding:30px 32px;
   border:1px solid color-mix(in srgb,var(--brand) 22%,var(--border));
   border-radius:20px;
   background:linear-gradient(135deg,color-mix(in srgb,var(--brand) 10%,var(--surface)),var(--surface) 62%);
   box-shadow:var(--shadow-sm)
}
 .emergency-hero:after {
   content:"";
   position:absolute;
   right:-60px;
   bottom:-90px;
   width:250px;
   height:250px;
   border-radius:50%;
   background:color-mix(in srgb,var(--brand) 7%,transparent);
   pointer-events:none
}
 .emergency-hero h2 {
   margin:6px 0 8px;
   color:var(--text-strong);
   font-size:30px;
   letter-spacing:-.035em
}
 .emergency-hero p {
   max-width:850px;
   margin:0;
   color:var(--muted);
   font-size:15px;
   line-height:1.65
}
 .emergency-hero__meta {
   display:flex;
   flex-wrap:wrap;
   gap:9px 18px;
   margin-top:18px;
   color:var(--text);
   font-size:12px;
   font-weight:700
}
 .emergency-hero__meta span {
   display:flex;
   align-items:center;
   gap:6px
}
 .emergency-hero__meta span:before {
   content:"";
   width:6px;
   height:6px;
   border-radius:50%;
   background:var(--brand)
}
 .emergency-hero__symbol {
   position:relative;
   z-index:1;
   display:grid;
   place-items:center;
   width:106px;
   height:106px;
   border-radius:28px;
   background:var(--brand);
   color:#fff;
   box-shadow:0 18px 35px color-mix(in srgb,var(--brand) 24%,transparent)
}
 .emergency-hero__symbol svg {
   width:62px;
   height:62px
}
 .emergency-alert {
   display:grid;
   grid-template-columns:46px minmax(0,1fr);
   gap:15px;
   align-items:start;
   padding:17px 19px;
   border:1px solid var(--warning-border);
   border-radius:15px;
   background:var(--warning-soft)
}
 .emergency-alert__icon {
   display:grid;
   place-items:center;
   width:40px;
   height:40px;
   border-radius:12px;
   background:var(--warning);
   color:#fff;
   font-size:20px;
   font-weight:900
}
 .emergency-alert h3 {
   margin:1px 0 4px;
   color:var(--text-strong);
   font-size:15px
}
 .emergency-alert p {
   margin:0;
   color:var(--muted);
   line-height:1.55
}
 .emergency-directory-tools {
   display:grid;
   grid-template-columns:minmax(230px,.38fr) minmax(0,1fr);
   gap:26px;
   align-items:end;
   padding:22px 24px
}
 .emergency-directory-tools__intro h3 {
   margin:4px 0 4px;
   color:var(--text-strong);
   font-size:19px
}
 .emergency-directory-tools__intro p {
   margin:0;
   color:var(--muted);
   line-height:1.5
}
 .emergency-filter-form {
   display:grid;
   grid-template-columns:minmax(260px,1.2fr) minmax(180px,.65fr) auto;
   gap:13px;
   align-items:end
}
 .emergency-filter-form label {
   display:grid;
   gap:7px;
   color:var(--text);
   font-size:12px;
   font-weight:800
}
 .emergency-filter-form .form-control {
   height:46px;
   min-height:46px
}
 .emergency-input-shell {
   position:relative;
   display:block
}
 .emergency-input-shell svg {
   position:absolute;
   left:14px;
   top:50%;
   width:18px;
   height:18px;
   transform:translateY(-50%);
   fill:none;
   stroke:var(--muted);
   stroke-width:1.8;
   stroke-linecap:round;
   pointer-events:none
}
 .emergency-input-shell input {
   padding-left:42px
}
 .emergency-filter-actions {
   display:flex;
   gap:8px
}
 .emergency-filter-actions .button {
   height:46px;
   white-space:nowrap
}
 .emergency-groups {
   display:grid;
   gap:20px
}
 .emergency-category {
   overflow:hidden
}
 .emergency-category__header {
   display:flex;
   align-items:center;
   justify-content:space-between;
   gap:18px;
   padding:21px 23px;
   border-bottom:1px solid var(--border);
   background:linear-gradient(180deg,var(--surface),var(--surface-2))
}
 .emergency-category__identity {
   display:flex;
   align-items:center;
   gap:14px;
   min-width:0
}
 .emergency-category__icon {
   display:grid;
   place-items:center;
   flex:0 0 48px;
   width:48px;
   height:48px;
   border-radius:14px;
   background:var(--brand-soft);
   color:var(--brand-deep);
   font-size:21px
}
 .emergency-category__header h3 {
   margin:3px 0 2px;
   color:var(--text-strong);
   font-size:18px
}
 .emergency-category__header p {
   margin:0;
   color:var(--muted);
   font-size:13px;
   line-height:1.45
}
 .emergency-category__count {
   flex:0 0 auto;
   padding:6px 10px;
   border-radius:999px;
   background:var(--surface-3);
   color:var(--muted);
   font-size:11px;
   font-weight:800
}
 .emergency-contact-grid {
   display:grid;
   grid-template-columns:repeat(2,minmax(0,1fr));
   gap:0
}
 .emergency-contact-card {
   display:flex;
   flex-direction:column;
   min-width:0;
   padding:22px 23px;
   border-right:1px solid var(--border);
   border-bottom:1px solid var(--border);
   background:var(--surface)
}
 .emergency-contact-card:nth-child(2n) {
   border-right:0
}
 .emergency-contact-card:nth-last-child(-n+2) {
   border-bottom:0
}
 .emergency-contact-card--priority {
   box-shadow:inset 4px 0 0 var(--brand)
}
 .emergency-contact-card__top {
   display:grid;
   grid-template-columns:48px minmax(0,1fr);
   gap:13px;
   align-items:center
}
 .emergency-contact-avatar {
   display:grid;
   place-items:center;
   width:48px;
   height:48px;
   border-radius:15px;
   background:var(--brand-soft);
   color:var(--brand-deep);
   font-size:17px;
   font-weight:900
}
 .emergency-contact-name-row {
   display:flex;
   align-items:center;
   justify-content:space-between;
   gap:10px
}
 .emergency-contact-identity h4 {
   margin:0;
   color:var(--text-strong);
   font-size:17px;
   overflow-wrap:anywhere
}
 .emergency-contact-identity p {
   margin:4px 0 0;
   color:var(--muted);
   font-size:13px
}
 .emergency-priority-badge {
   flex:0 0 auto;
   padding:4px 8px;
   border-radius:999px;
   background:var(--brand-soft);
   color:var(--brand-deep);
   font-size:10px;
   font-weight:900;
   text-transform:uppercase;
   letter-spacing:.05em
}
 .emergency-contact-details {
   display:grid;
   grid-template-columns:repeat(2,minmax(0,1fr));
   gap:10px;
   margin:17px 0 0
}
 .emergency-contact-details>div {
   padding:11px 12px;
   border:1px solid var(--border);
   border-radius:11px;
   background:var(--surface-2)
}
 .emergency-contact-details dt {
   color:var(--muted);
   font-size:10px;
   font-weight:900;
   letter-spacing:.07em;
   text-transform:uppercase
}
 .emergency-contact-details dd {
   margin:4px 0 0;
   color:var(--text);
   font-size:13px;
   font-weight:700;
   overflow-wrap:anywhere
}
 .emergency-contact-note {
   margin-top:14px;
   padding:12px 13px;
   border-left:3px solid var(--brand);
   border-radius:0 10px 10px 0;
   background:var(--surface-2)
}
 .emergency-contact-note strong {
   color:var(--text-strong);
   font-size:11px;
   text-transform:uppercase;
   letter-spacing:.05em
}
 .emergency-contact-note p {
   margin:4px 0 0;
   color:var(--muted);
   font-size:13px;
   line-height:1.5
}
 .emergency-contact-actions {
   display:grid;
   gap:9px;
   margin-top:auto;
   padding-top:18px
}
 .emergency-call-button {
   display:flex;
   align-items:center;
   justify-content:center;
   gap:10px;
   min-height:50px
}
 .emergency-call-button svg {
   width:20px;
   height:20px;
   fill:none;
   stroke:currentColor;
   stroke-width:1.8;
   stroke-linecap:round;
   stroke-linejoin:round
}
 .emergency-call-button span {
   display:grid;
   line-height:1.15;
   text-align:left
}
 .emergency-call-button small {
   font-size:9px;
   font-weight:800;
   letter-spacing:.07em;
   text-transform:uppercase;
   opacity:.78
}
 .emergency-secondary-actions {
   display:flex;
   flex-wrap:wrap;
   gap:8px
}
 .emergency-secondary-actions .button {
   flex:1 1 auto;
   min-height:40px
}
 .emergency-empty-state {
   display:grid;
   justify-items:center;
   padding:48px 24px;
   text-align:center
}
 .emergency-empty-state__icon {
   display:grid;
   place-items:center;
   width:58px;
   height:58px;
   margin-bottom:12px;
   border-radius:18px;
   background:var(--surface-3);
   color:var(--muted);
   font-size:26px
}
 .emergency-empty-state h3 {
   margin:0;
   color:var(--text-strong)
}
 .emergency-empty-state p {
   max-width:580px;
   margin:8px 0 18px;
   color:var(--muted);
   line-height:1.55
}
 .emergency-directory-footer {
   padding:17px 20px;
   border:1px dashed var(--border);
   border-radius:14px;
   background:var(--surface-2);
   text-align:center
}
 .emergency-directory-footer strong {
   color:var(--text-strong)
}
 .emergency-directory-footer p {
   margin:4px 0 0;
   color:var(--muted);
   font-size:13px
}
 @media(max-width:1000px) {
   .emergency-directory-tools {
     grid-template-columns:1fr
  }
   .emergency-filter-form {
     grid-template-columns:1fr 1fr
  }
   .emergency-filter-actions {
     grid-column:1/-1
  }
   .emergency-contact-grid {
     grid-template-columns:1fr
  }
   .emergency-contact-card,.emergency-contact-card:nth-child(2n) {
     border-right:0;
     border-bottom:1px solid var(--border)
  }
   .emergency-contact-card:last-child {
     border-bottom:0
  }

}
 @media(max-width:700px) {
   .emergency-page {
     gap:16px
  }
   .public-contact-bar {
     align-items:flex-start;
     flex-direction:column
  }
   .emergency-hero {
     grid-template-columns:1fr;
     padding:23px 20px
  }
   .emergency-hero h2 {
     font-size:25px
  }
   .emergency-hero__symbol {
     display:none
  }
   .emergency-hero__meta {
     display:grid
  }
   .emergency-alert {
     grid-template-columns:38px minmax(0,1fr);
     padding:15px
  }
   .emergency-alert__icon {
     width:34px;
     height:34px
  }
   .emergency-directory-tools {
     padding:19px 17px
  }
   .emergency-filter-form {
     grid-template-columns:1fr
  }
   .emergency-filter-actions {
     grid-column:auto;
     flex-direction:column
  }
   .emergency-filter-actions .button {
     width:100%
  }
   .emergency-category__header {
     align-items:flex-start;
     flex-direction:column;
     padding:18px
  }
   .emergency-category__count {
     align-self:flex-start
  }
   .emergency-contact-card {
     padding:19px 17px
  }
   .emergency-contact-details {
     grid-template-columns:1fr
  }
   .emergency-contact-name-row {
     align-items:flex-start;
     flex-direction:column
  }
   .emergency-secondary-actions {
     flex-direction:column
  }
   .emergency-secondary-actions .button {
     width:100%
  }

}

/* Emergency contacts phone layout. */
@media (max-width: 760px) {
  .emergency-hero,
  .emergency-alert,
  .emergency-contact-grid,
  .emergency-contact-card__top { grid-template-columns: minmax(0, 1fr); }
  .emergency-contact-grid > *,
  .emergency-contact-card__top > * { min-width: 0; }
}
/* ===== END pages/emergency.css ===== */

/* ===== BEGIN pages/communications.css ===== */
/*
 * ARBS stylesheet: pages/communications.css
 * Purpose: Communications dashboard, inbox, conversation queues, contact identity and WhatsApp message cards.
 * Architecture: Page layer; communications-only selectors and responsive states.
 */
.relationship-list--events {
  gap: 0;
  padding: 0 18px 18px;
}


/* Communications dashboard and WhatsApp conversation cards */
 .communications-heading {
   margin-bottom: 18px;

}
 .communications-metrics {
   margin-bottom: 20px;

}
 .communications-dashboard-grid {
   display:grid;
   grid-template-columns:minmax(0,1fr) minmax(0,1fr);
   gap:20px;
   align-items:start;

}
 .communications-panel {
   overflow:hidden;

}
 .communications-panel-header {
   padding:20px 22px 16px;
   gap:16px;

}
 .communications-panel-header h3 {
   margin:0 0 4px;

}
 .communications-panel-header p {
   margin:0;

}
 .communications-card-list {
   display:grid;
   gap:10px;
   padding:0 16px 18px;

}
 .communication-row-card {
   display:grid;
   grid-template-columns:42px minmax(0,1fr) auto;
   gap:13px;
   align-items:center;
   padding:13px 14px;
   border:1px solid var(--border);
   border-radius:14px;
   background:var(--surface);
   color:var(--text);
   text-decoration:none;
   transition:border-color .16s ease, box-shadow .16s ease, transform .16s ease;

}
 .communication-row-card:hover {
   border-color:var(--brand);
   box-shadow:0 8px 22px rgba(15,63,45,.08);
   transform:translateY(-1px);

}
 .communication-avatar {
   width:42px;
   height:42px;
   border-radius:12px;
   display:grid;
   place-items:center;
   background:var(--surface-2);
   color:var(--brand);
   font-weight:800;

}
 .communication-avatar.outbound {
   background:rgba(27,119,89,.12);

}
 .communication-card-main {
   min-width:0;
   display:grid;
   gap:5px;

}
 .communication-card-title-row {
   min-width:0;
   display:flex;
   align-items:baseline;
   justify-content:space-between;
   gap:14px;

}
 .communication-card-title-row strong {
   min-width:0;
   overflow:hidden;
   text-overflow:ellipsis;
   white-space:nowrap;

}
 .communication-card-title-row time {
   flex:none;
   color:var(--muted);
   font-size:12px;
   white-space:nowrap;

}
 .communication-preview {
   margin:0;
   color:var(--text);
   line-height:1.45;
   overflow-wrap:anywhere;

}
 .communication-meta {
   display:flex;
   flex-wrap:wrap;
   gap:6px 14px;
   color:var(--muted);
   font-size:12px;

}
 .communication-meta span:not(:first-child)::before {
   content:"•";
   margin-right:8px;
   opacity:.65;

}
 .communication-meta .window-open {
   color:var(--brand);
   font-weight:700;

}
 .communications-filter-bar {
   margin-bottom:18px;

}
 .conversation-list-panel {
   padding-bottom:2px;

}
 .conversation-card-list {
   gap:12px;

}
 .conversation-row-card {
   grid-template-columns:46px minmax(0,1fr) minmax(125px,auto);
   padding:15px 16px;

}
 .conversation-identity {
   margin-bottom:1px;

}
 .conversation-card-actions {
   display:flex;
   flex-direction:column;
   align-items:flex-end;
   justify-content:center;
   gap:7px;

}
@media (max-width: 1050px) {
   .communications-dashboard-grid {
     grid-template-columns:1fr;

  }

}
 @media (max-width: 760px) {
   .communication-row-card, .conversation-row-card {
     grid-template-columns:38px minmax(0,1fr);
     align-items:start;

  }
   .communication-avatar {
     width:38px;
     height:38px;

  }
   .communication-row-card > .badge, .conversation-card-actions {
     grid-column:2;
     justify-self:start;
     align-items:flex-start;
     flex-direction:row;
     flex-wrap:wrap;

  }
   .communication-card-title-row {
     display:grid;
     gap:2px;

  }
   .communication-card-title-row time {
     white-space:normal;

  }
   .communications-panel-header {
     padding:17px 16px 14px;

  }
   .communications-card-list {
     padding:0 12px 14px;

  }

}

/* Inbox workspace */
.communications-inbox-page {
  display: grid;
  gap: 20px;
}

.communications-inbox-hero {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  padding: 24px 26px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: linear-gradient(135deg, var(--surface), var(--surface-2));
  box-shadow: var(--shadow-sm);
}

.communications-inbox-hero h2 {
  margin: 4px 0 7px;
}

.communications-inbox-hero p {
  max-width: 760px;
  margin: 0;
  color: var(--muted);
}

.communications-inbox-hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.inbox-status-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.inbox-status-tile {
  display: grid;
  gap: 5px;
  min-width: 0;
  padding: 17px 18px;
  border: 1px solid var(--border);
  border-radius: 15px;
  background: var(--surface);
  color: var(--text);
  text-decoration: none;
  box-shadow: var(--shadow-sm);
  transition: border-color .16s ease, box-shadow .16s ease, transform .16s ease;
}

.inbox-status-tile:hover,
.inbox-status-tile.active {
  border-color: var(--brand);
  box-shadow: 0 10px 24px rgba(15, 63, 45, .1);
  transform: translateY(-1px);
}

.inbox-status-tile.unread {
  background: linear-gradient(145deg, #f3fbf8, #ffffff);
  border-color: #b8e8df;
}

.inbox-status-tile.read {
  background: linear-gradient(145deg, #f7f8fa, #ffffff);
}

.inbox-status-tile.replied {
  background: linear-gradient(145deg, #f2f8ff, #ffffff);
  border-color: #c9dff5;
}

.inbox-status-label {
  display: flex;
  align-items: center;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .01em;
}

.inbox-status-tile strong {
  font-size: 27px;
  line-height: 1.05;
}

.inbox-status-tile small {
  color: var(--muted);
}

.status-dot {
  width: 8px;
  height: 8px;
  flex: none;
  border-radius: 50%;
  background: currentColor;
}

.inbox-status-tile.unread .status-dot,
.inbox-message-status.status-received {
  color: #0f8a78;
}

.inbox-status-tile.read .status-dot,
.inbox-message-status.status-read {
  color: #667085;
}

.inbox-status-tile.replied .status-dot,
.inbox-message-status.status-replied {
  color: #1769aa;
}

.inbox-message-status.status-archived {
  color: #8a5a14;
}

.communications-inbox-filters {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) minmax(190px, 260px) auto auto;
  align-items: end;
  gap: 14px;
  padding: 18px;
}

.communications-inbox-filters label {
  display: grid;
  gap: 7px;
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.communications-inbox-panel {
  overflow: hidden;
}

.communications-inbox-panel-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding: 21px 22px 16px;
  border-bottom: 1px solid var(--border);
}

.communications-inbox-panel-header h3 {
  margin: 0 0 4px;
}

.communications-inbox-panel-header p {
  margin: 0;
  color: var(--muted);
}

.inbox-result-count {
  flex: none;
  padding: 6px 10px;
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--brand);
  font-size: 12px;
  font-weight: 800;
}

.inbox-message-list {
  display: grid;
  gap: 11px;
  padding: 16px;
}

.inbox-message-card {
  position: relative;
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr) minmax(118px, auto);
  align-items: center;
  gap: 14px;
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: 15px;
  background: var(--surface);
  transition: border-color .16s ease, box-shadow .16s ease, transform .16s ease;
}

.inbox-message-card:hover {
  border-color: #9ccfc5;
  box-shadow: 0 9px 24px rgba(15, 63, 45, .08);
  transform: translateY(-1px);
}

.inbox-message-card.is-unread {
  border-color: #9fd9ce;
  background: linear-gradient(90deg, #eefaf7 0, #ffffff 34%);
  box-shadow: inset 4px 0 0 var(--brand);
}

.inbox-message-card.status-replied {
  background: linear-gradient(90deg, #f3f8fd 0, #ffffff 30%);
}

.inbox-message-card.status-archived {
  opacity: .82;
  background: var(--surface-2);
}

.inbox-message-avatar {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 13px;
  background: var(--surface-2);
  color: var(--brand);
  font-weight: 900;
}

.is-unread .inbox-message-avatar {
  background: var(--brand);
  color: #fff;
}

.inbox-message-content {
  min-width: 0;
  display: grid;
  gap: 7px;
}

.inbox-message-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.inbox-message-contact {
  min-width: 0;
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 6px 10px;
}

.inbox-message-contact strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.is-unread .inbox-message-contact strong {
  color: var(--brand-hover);
}

.inbox-message-contact span,
.inbox-message-heading time,
.inbox-message-meta {
  color: var(--muted);
  font-size: 12px;
}

.inbox-message-heading time {
  flex: none;
  white-space: nowrap;
}

.inbox-message-preview {
  margin: 0;
  color: var(--text);
  line-height: 1.48;
  overflow-wrap: anywhere;
}

.is-unread .inbox-message-preview {
  font-weight: 650;
}

.inbox-message-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 14px;
}

.inbox-message-meta span:not(:first-child)::before {
  content: "•";
  margin-right: 8px;
  opacity: .6;
}

.inbox-message-actions {
  display: grid;
  justify-items: end;
  gap: 10px;
}

.inbox-message-status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 5px 9px;
  border: 1px solid currentColor;
  border-radius: 999px;
  background: #fff;
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
  letter-spacing: .04em;
}

.inbox-message-status .status-dot {
  width: 7px;
  height: 7px;
}

.inbox-empty-state {
  display: grid;
  justify-items: center;
  gap: 8px;
  padding: 48px 22px;
  text-align: center;
}

.inbox-empty-state h3,
.inbox-empty-state p {
  margin: 0;
}

.inbox-empty-state p {
  color: var(--muted);
}

.inbox-empty-icon {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 15px;
  background: var(--surface-2);
  color: var(--brand);
  font-size: 22px;
  font-weight: 900;
}

@media (max-width: 980px) {
  .inbox-status-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .communications-inbox-filters {
    grid-template-columns: minmax(0, 1fr) minmax(190px, 240px);
  }

  .communications-inbox-filters .report-filter-action {
    width: 100%;
  }
}

@media (max-width: 720px) {
  .communications-inbox-hero,
  .communications-inbox-panel-header,
  .inbox-message-heading {
    display: grid;
  }

  .communications-inbox-hero {
    padding: 20px;
  }

  .communications-inbox-hero-actions {
    justify-content: flex-start;
  }

  .communications-inbox-filters,
  .inbox-status-summary {
    grid-template-columns: 1fr;
  }

  .inbox-message-card {
    grid-template-columns: 40px minmax(0, 1fr);
    align-items: start;
    padding: 14px;
  }

  .inbox-message-avatar {
    width: 40px;
    height: 40px;
  }

  .inbox-message-actions {
    grid-column: 2;
    grid-template-columns: auto auto;
    align-items: center;
    justify-content: start;
    justify-items: start;
  }

  .inbox-message-heading time {
    white-space: normal;
  }
}

@media (max-width: 460px) {
  .communications-inbox-hero-actions,
  .communications-inbox-hero-actions .button,
  .inbox-message-actions,
  .inbox-message-actions .button {
    width: 100%;
  }

  .inbox-message-actions {
    grid-template-columns: 1fr;
  }
}

/* Conversation detail workspace */
.conversation-workspace {
  display: grid;
  gap: 18px;
}

.conversation-page-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
}

.conversation-page-heading h2 {
  margin: 4px 0 6px;
}

.conversation-page-heading p,
.conversation-card-heading p {
  margin: 0;
  color: var(--muted);
}

.conversation-contact-strip {
  display: grid;
  grid-template-columns: minmax(250px, .9fr) minmax(0, 2.1fr);
  gap: 24px;
  align-items: center;
  padding: 16px 20px;
}

.conversation-contact-primary,
.conversation-contact-title-row {
  display: flex;
  align-items: center;
  min-width: 0;
}

.conversation-contact-primary {
  gap: 13px;
}

.conversation-contact-copy {
  min-width: 0;
}

.conversation-contact-title-row {
  gap: 10px;
  flex-wrap: wrap;
}

.conversation-contact-title-row h3 {
  margin: 0;
  overflow-wrap: anywhere;
}

.conversation-contact-avatar {
  width: 44px;
  height: 44px;
  display: grid;
  flex: none;
  place-items: center;
  border-radius: 14px;
  background: var(--brand-soft);
  color: var(--brand-deep);
  font-size: 17px;
  font-weight: 900;
  text-transform: uppercase;
}

.conversation-phone-link {
  display: inline-block;
  margin-top: 3px;
  color: var(--brand);
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
}

.conversation-phone-link:hover,
.chat-message__link:hover {
  text-decoration: underline;
}

.conversation-state-badge,
.conversation-message-count {
  display: inline-flex;
  align-items: center;
  flex: none;
  min-height: 28px;
  padding: 5px 9px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.conversation-state-badge.status-open { border-color: #9fd9ce; background: #eefaf7; color: #0b7163; }
.conversation-state-badge.status-pending { border-color: #eed39c; background: #fff8e8; color: #8a5a14; }
.conversation-state-badge.status-resolved { border-color: #bfd9f2; background: #f2f8ff; color: #1769aa; }
.conversation-state-badge.status-closed { color: #667085; }

.conversation-context-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  margin: 0;
}

.conversation-context-item {
  min-width: 0;
  padding: 2px 16px;
  border-left: 1px solid var(--border);
}

.conversation-context-item dt,
.conversation-activity-card dt {
  color: var(--muted);
  font-size: 11px;
  font-weight: 750;
}

.conversation-context-item dd,
.conversation-activity-card dd {
  margin: 4px 0 0;
  color: var(--text-strong);
  font-weight: 800;
  overflow-wrap: anywhere;
}

.conversation-main-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(290px, 340px);
  gap: 18px;
  align-items: start;
}

.conversation-chat-panel {
  min-width: 0;
  overflow: hidden;
}

.conversation-thread-header,
.conversation-card-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 17px 20px;
  border-bottom: 1px solid var(--border);
}

.conversation-thread-header {
  align-items: center;
}

.conversation-thread-header h3,
.conversation-card-heading h3 {
  margin: 3px 0 0;
}

.conversation-thread-scroll {
  display: flex;
  flex-direction: column;
  gap: 11px;
  min-height: 440px;
  height: clamp(440px, 58vh, 720px);
  overflow: auto;
  padding: 22px;
  background: var(--surface-2);
  scrollbar-gutter: stable;
}

.chat-message {
  position: relative;
  max-width: min(72%, 720px);
  padding: 11px 14px;
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: var(--shadow-sm);
}

.chat-message--inbound {
  align-self: flex-start;
  border-bottom-left-radius: 5px;
  background: var(--surface);
  color: var(--text);
}

.chat-message--outbound {
  align-self: flex-end;
  border-color: #9fd9ce;
  border-bottom-right-radius: 5px;
  background: #e8f7f3;
  color: #123b35;
}

.chat-message__meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 5px 9px;
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 10px;
}

.chat-message__meta strong { color: inherit; font-weight: 850; }
.chat-message__meta time { margin-left: auto; }
.chat-delivery-state { padding: 2px 6px; border-radius: 999px; background: rgba(255,255,255,.65); font-weight: 750; }
.chat-message__body { color: inherit; line-height: 1.5; overflow-wrap: anywhere; }
.chat-message__link { display: inline-block; margin-top: 7px; color: var(--brand); font-size: 11px; font-weight: 800; text-decoration: none; }

.conversation-composer {
  border-top: 1px solid var(--border);
}

.reply-window-banner {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr);
  gap: 11px;
  align-items: start;
  padding: 12px 18px;
  border-bottom: 1px solid var(--border);
}

.reply-window-banner > div:last-child { display: grid; gap: 2px; }
.reply-window-banner span { color: var(--muted); font-size: 12px; line-height: 1.45; }
.reply-window-banner--open { background: #eefaf7; }
.reply-window-banner--closed { background: #fff8e8; }

.reply-window-icon {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: #fff;
  color: var(--brand);
  font-size: 15px;
  font-weight: 900;
  box-shadow: var(--shadow-sm);
}

.reply-window-banner--closed .reply-window-icon { color: #8a5a14; }

.conversation-reply-form {
  display: grid;
  gap: 13px;
  padding: 16px 18px 18px;
}

.conversation-reply-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(240px, .7fr);
  gap: 14px;
  align-items: start;
}

.conversation-reply-grid--single { grid-template-columns: minmax(0, 1fr); }
.conversation-reply-message textarea { min-height: 96px; resize: vertical; }
.conversation-reply-actions { display: flex; justify-content: flex-end; }

.conversation-sidebar {
  display: grid;
  gap: 14px;
  position: sticky;
  top: 18px;
}

.conversation-management-card,
.conversation-activity-card {
  overflow: hidden;
}

.conversation-management-card .conversation-card-heading { display: block; }
.conversation-management-form { display: grid; gap: 13px; padding: 16px 18px 18px; }

.conversation-activity-card {
  padding: 17px 18px;
}

.conversation-activity-card dl {
  display: grid;
  gap: 0;
  margin: 10px 0 0;
}

.conversation-activity-card dl > div {
  display: grid;
  grid-template-columns: minmax(90px, .8fr) minmax(0, 1.2fr);
  gap: 12px;
  padding: 10px 0;
  border-top: 1px solid var(--border);
}

.conversation-activity-card dd {
  text-align: right;
}

html.dark .conversation-state-badge.status-open,
html.dark .reply-window-banner--open { border-color: #1d665e; background: #123d39; color: #d9fbf4; }
html.dark .conversation-state-badge.status-pending,
html.dark .reply-window-banner--closed { border-color: #705a2a; background: #3b301a; color: #ffe6a8; }
html.dark .conversation-state-badge.status-resolved { border-color: #315d85; background: #18344e; color: #d8ebff; }
html.dark .conversation-thread-scroll { background: #0d1724; }
html.dark .chat-message--inbound { border-color: #3b4d63; background: #1c2a3a; color: #f4f7fb; }
html.dark .chat-message--outbound { border-color: #28786e; background: #153f3a; color: #f1fbf9; }
html.dark .chat-message__meta { color: #bcc8d6; }
html.dark .chat-message__meta strong { color: #ffffff; }
html.dark .chat-delivery-state,
html.dark .reply-window-icon { background: rgba(255,255,255,.1); color: inherit; }
html.dark .chat-message__link { color: #80d8ca; }

@media (max-width: 1180px) {
  .conversation-contact-strip { grid-template-columns: 1fr; gap: 15px; }
  .conversation-context-item:first-child { border-left: 0; padding-left: 0; }
  .conversation-main-layout { grid-template-columns: minmax(0, 1fr) minmax(270px, 310px); }
  .conversation-reply-grid { grid-template-columns: 1fr; }
}

@media (max-width: 900px) {
  .conversation-main-layout { grid-template-columns: minmax(0, 1fr); }
  .conversation-sidebar { position: static; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .conversation-thread-scroll { height: clamp(420px, 56vh, 620px); }
}

@media (max-width: 720px) {
  .conversation-page-heading { display: grid; gap: 14px; }
  .conversation-page-heading .button { width: 100%; justify-content: center; }
  .conversation-contact-strip { padding: 15px 16px; }
  .conversation-context-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .conversation-context-item { padding: 9px 12px; border-top: 1px solid var(--border); }
  .conversation-context-item:nth-child(odd) { border-left: 0; padding-left: 0; }
  .conversation-sidebar { grid-template-columns: 1fr; }
  .conversation-thread-header,
  .conversation-card-heading { padding: 15px 16px; }
  .conversation-thread-scroll { min-height: 380px; height: 54vh; padding: 15px; }
  .chat-message { max-width: 90%; }
  .chat-message__meta time { width: 100%; margin-left: 0; }
  .conversation-reply-form { padding: 14px 16px 16px; }
  .conversation-reply-actions,
  .conversation-reply-actions .button { width: 100%; }
  .conversation-reply-actions .button { justify-content: center; }
}

@media (max-width: 460px) {
  .conversation-contact-title-row { display: grid; justify-items: start; }
  .conversation-context-list { grid-template-columns: 1fr; }
  .conversation-context-item,
  .conversation-context-item:nth-child(odd) { padding: 9px 0; border-left: 0; }
  .conversation-thread-header { display: grid; }
  .conversation-thread-scroll { height: 52vh; }
  .chat-message { max-width: 95%; }
}

/* Communications phone layout. */
@media (max-width: 760px) {
  .communications-dashboard-grid,
  .inbox-status-summary,
  .communications-inbox-filters,
  .conversation-context-grid,
  .conversation-contact-details,
  .conversation-reply-grid,
  .conversation-reply-grid--single { grid-template-columns: minmax(0, 1fr); }
  .communication-row-card,
  .conversation-row-card,
  .inbox-message-card { grid-template-columns: 40px minmax(0, 1fr); align-items: start; }
  .communication-row-card > *,
  .conversation-row-card > *,
  .inbox-message-card > *,
  .communications-dashboard-grid > *,
  .inbox-status-summary > *,
  .conversation-context-grid > * { min-width: 0; }
}
@media (max-width: 460px) {
  .communication-row-card,
  .conversation-row-card,
  .inbox-message-card { grid-template-columns: minmax(0, 1fr); }
  .communication-row-card__icon,
  .conversation-row-card__icon,
  .inbox-message-avatar { margin-bottom: 4px; }
}


/* Outbound message workspace */
.outbound-page,
.outbound-detail-page {
  display: grid;
  gap: 20px;
}

.outbound-hero,
.outbound-detail-hero {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  padding: 24px 26px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: linear-gradient(135deg, var(--surface), var(--surface-2));
  box-shadow: var(--shadow-sm);
}

.outbound-hero h2,
.outbound-detail-hero h2 {
  margin: 4px 0 7px;
}

.outbound-hero p,
.outbound-detail-hero p {
  max-width: 760px;
  margin: 0;
  color: var(--muted);
}

.outbound-eyebrow,
.outbound-section-kicker {
  display: block;
  color: var(--brand);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.outbound-hero-actions,
.outbound-filter-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.outbound-filter-card {
  padding: 18px;
}

.outbound-filter-grid {
  display: grid;
  grid-template-columns: minmax(300px, 1fr) minmax(170px, 220px) minmax(170px, 220px) auto;
  align-items: end;
  gap: 14px;
}

.outbound-filter-grid label {
  display: grid;
  gap: 7px;
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.outbound-list-panel {
  overflow: hidden;
}

.outbound-panel-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 22px 16px;
  border-bottom: 1px solid var(--border);
}

.outbound-panel-header h3 {
  margin: 0 0 4px;
}

.outbound-panel-header p {
  margin: 0;
  color: var(--muted);
}

.outbound-message-list {
  display: grid;
}

.outbound-message-row {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) auto;
  gap: 16px;
  align-items: start;
  padding: 18px 22px;
  border-bottom: 1px solid var(--border);
  transition: background-color .16s ease;
}

.outbound-message-row:last-child {
  border-bottom: 0;
}

.outbound-message-row:hover {
  background: var(--surface-2);
}

.outbound-channel-icon {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: var(--surface-2);
  color: var(--brand);
  font-size: 13px;
  font-weight: 900;
  letter-spacing: -.02em;
}

.outbound-channel-email {
  background: #eef5ff;
  color: #245f9e;
}

.outbound-channel-whatsapp {
  background: #ecf9f3;
  color: #0f8a78;
}

.outbound-channel-sms {
  background: #f7f3ff;
  color: #6941c6;
}

.outbound-message-main {
  min-width: 0;
  display: grid;
  gap: 7px;
}

.outbound-message-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.outbound-message-recipient {
  min-width: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px 10px;
}

.outbound-message-recipient strong {
  overflow-wrap: anywhere;
}

.outbound-message-recipient span,
.outbound-message-heading time {
  color: var(--muted);
  font-size: 12px;
}

.outbound-message-heading time {
  flex: none;
  white-space: nowrap;
}

.outbound-message-main h4 {
  margin: 0;
  font-size: 15px;
}

.outbound-message-main p {
  margin: 0;
  color: var(--text);
  line-height: 1.55;
  overflow-wrap: anywhere;
}

.outbound-message-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 14px;
  color: var(--muted);
  font-size: 12px;
}

.outbound-message-meta span:not(:first-child)::before {
  content: "•";
  margin-right: 8px;
  opacity: .6;
}

.outbound-message-actions {
  display: flex;
  min-width: 126px;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
}

.outbound-empty-state {
  display: grid;
  justify-items: center;
  gap: 6px;
  padding: 44px 24px;
  text-align: center;
}

.outbound-empty-state p {
  max-width: 520px;
  margin: 0;
  color: var(--muted);
}

.outbound-empty-state.compact {
  justify-items: start;
  padding: 12px 0 4px;
  text-align: left;
}

.outbound-back-link {
  display: inline-flex;
  margin-bottom: 12px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
}

.outbound-back-link:hover {
  color: var(--brand);
}

.outbound-detail-hero-status {
  display: grid;
  justify-items: end;
  gap: 8px;
  flex: none;
}

.outbound-detail-hero-status small {
  color: var(--muted);
  white-space: nowrap;
}

.outbound-detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(300px, .75fr);
  gap: 20px;
  align-items: start;
}

.outbound-detail-main,
.outbound-detail-sidebar {
  display: grid;
  gap: 20px;
  min-width: 0;
}

.outbound-message-content-card,
.outbound-events-card,
.outbound-info-card,
.outbound-error-card,
.outbound-action-card {
  overflow: hidden;
}

.outbound-section-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 22px 16px;
  border-bottom: 1px solid var(--border);
}

.outbound-section-header.compact {
  padding-bottom: 14px;
}

.outbound-section-header h3 {
  margin: 4px 0 0;
}

.outbound-channel-pill,
.outbound-event-count {
  flex: none;
  padding: 6px 9px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.outbound-message-body {
  min-height: 150px;
  padding: 24px 26px 28px;
  color: var(--text);
  font-size: 15px;
  line-height: 1.75;
  overflow-wrap: anywhere;
  white-space: normal;
}

.outbound-error-copy {
  padding: 20px 22px 22px;
  color: var(--danger, #b42318);
  line-height: 1.6;
  overflow-wrap: anywhere;
}

.outbound-event-timeline {
  position: relative;
  display: grid;
  gap: 0;
  padding: 6px 22px 20px;
}

.outbound-event-item {
  position: relative;
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 12px;
  padding: 15px 0;
}

.outbound-event-item:not(:last-child)::before {
  content: "";
  position: absolute;
  left: 5px;
  top: 29px;
  bottom: -1px;
  width: 2px;
  background: var(--border);
}

.outbound-event-marker {
  position: relative;
  z-index: 1;
  width: 12px;
  height: 12px;
  margin-top: 4px;
  border: 3px solid var(--surface);
  border-radius: 50%;
  background: var(--brand);
  box-shadow: 0 0 0 1px var(--brand);
}

.outbound-event-item > div {
  display: grid;
  gap: 4px;
}

.outbound-event-item span,
.outbound-event-item small {
  color: var(--muted);
  font-size: 12px;
  overflow-wrap: anywhere;
}

.outbound-detail-list {
  display: grid;
  margin: 0;
  padding: 4px 22px 18px;
}

.outbound-detail-list > div {
  display: grid;
  grid-template-columns: minmax(90px, .7fr) minmax(0, 1.3fr);
  gap: 16px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}

.outbound-detail-list > div:last-child {
  border-bottom: 0;
}

.outbound-detail-list dt {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.outbound-detail-list dd {
  min-width: 0;
  margin: 0;
  text-align: right;
  overflow-wrap: anywhere;
}

.outbound-break-value {
  word-break: break-all;
}

.outbound-linked-records {
  display: grid;
  padding: 4px 22px 18px;
}

.outbound-linked-records > div,
.outbound-linked-records > a {
  display: grid;
  gap: 4px;
  padding: 13px 0;
  border-bottom: 1px solid var(--border);
  color: var(--text);
  text-decoration: none;
}

.outbound-linked-records > :last-child {
  border-bottom: 0;
}

.outbound-linked-records span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.outbound-linked-records a:hover strong {
  color: var(--brand);
}

.outbound-action-card {
  padding: 20px 22px 22px;
}

.outbound-action-card h3 {
  margin: 0 0 7px;
}

.outbound-action-card p {
  margin: 0 0 16px;
  color: var(--muted);
  line-height: 1.55;
}

.outbound-retry-button {
  width: 100%;
}

@media (max-width: 980px) {
  .outbound-filter-grid {
    grid-template-columns: minmax(0, 1fr) minmax(160px, .5fr) minmax(160px, .5fr);
  }

  .outbound-filter-actions {
    grid-column: 1 / -1;
    justify-content: flex-start;
  }

  .outbound-detail-layout {
    grid-template-columns: 1fr;
  }

  .outbound-detail-sidebar {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .outbound-action-card {
    grid-column: 1 / -1;
  }
}

@media (max-width: 760px) {
  .outbound-hero,
  .outbound-detail-hero {
    display: grid;
    padding: 20px 18px;
  }

  .outbound-hero-actions,
  .outbound-detail-hero-status {
    justify-content: flex-start;
    justify-items: start;
  }

  .outbound-detail-hero-status small {
    white-space: normal;
  }

  .outbound-filter-grid {
    grid-template-columns: 1fr;
  }

  .outbound-filter-actions {
    grid-column: auto;
  }

  .outbound-filter-actions .button {
    flex: 1 1 150px;
  }

  .outbound-message-row {
    grid-template-columns: 42px minmax(0, 1fr);
    gap: 12px;
    padding: 16px;
  }

  .outbound-channel-icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
  }

  .outbound-message-actions {
    grid-column: 2;
    min-width: 0;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
  }

  .outbound-message-heading {
    display: grid;
    gap: 4px;
  }

  .outbound-message-heading time {
    white-space: normal;
  }

  .outbound-detail-sidebar {
    grid-template-columns: 1fr;
  }

  .outbound-section-header,
  .outbound-panel-header {
    padding: 18px 16px 14px;
  }

  .outbound-message-body {
    padding: 20px 18px 24px;
  }

  .outbound-event-timeline,
  .outbound-detail-list,
  .outbound-linked-records {
    padding-left: 16px;
    padding-right: 16px;
  }

  .outbound-detail-list > div {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .outbound-detail-list dd {
    text-align: left;
  }
}

@media (max-width: 430px) {
  .outbound-hero-actions,
  .outbound-filter-actions {
    display: grid;
    grid-template-columns: 1fr;
    width: 100%;
  }

  .outbound-hero-actions .button,
  .outbound-filter-actions .button,
  .outbound-message-actions .button {
    width: 100%;
  }

  .outbound-message-actions {
    display: grid;
    justify-items: start;
  }

  .outbound-message-meta span {
    width: 100%;
  }

  .outbound-message-meta span:not(:first-child)::before {
    display: none;
  }
}
/* ===== END pages/communications.css ===== */

/* ===== BEGIN pages/notifications.css ===== */
/*
 * ARBS stylesheet: pages/notifications.css
 * Purpose: Notification centre, filters and notification feed.
 * Architecture: Notification-centre selectors only.
 */

.notification-centre {
   display:grid;
   gap:18px
}
 .notification-hero {
   display:flex;
   align-items:flex-start;
   justify-content:space-between;
   gap:24px;
   padding:24px 26px;
   border:1px solid var(--border);
   border-radius:18px;
   background:linear-gradient(135deg,var(--surface),var(--surface-2));
   box-shadow:var(--shadow-sm)
}
 .notification-hero h2 {
   margin:4px 0 7px;
   color:var(--text-strong);
   font-size:30px;
   letter-spacing:-.035em
}
 .notification-hero p {
   max-width:760px;
   margin:0;
   color:var(--muted);
   line-height:1.6
}
 .notification-hero-actions {
   display:flex;
   align-items:center;
   justify-content:flex-end;
   gap:10px;
   flex-wrap:wrap
}
 .notification-hero-actions form {
   margin:0
}
 .notification-hero-actions .button {
   white-space:nowrap
}
 .notification-hero-actions .button:disabled {
   cursor:not-allowed;
   opacity:.48
}
 .notification-summary {
   display:grid;
   grid-template-columns:repeat(3,minmax(0,1fr));
   gap:14px
}
 .notification-summary-card {
   display:grid;
   gap:5px;
   padding:18px 20px;
   border:1px solid var(--border);
   border-radius:15px;
   background:var(--surface);
   box-shadow:var(--shadow-sm)
}
 .notification-summary-card span {
   color:var(--muted);
   font-size:12px;
   font-weight:800;
   letter-spacing:.055em;
   text-transform:uppercase
}
 .notification-summary-card strong {
   color:var(--text-strong);
   font-size:28px;
   line-height:1.05
}
 .notification-summary-card small {
   color:var(--muted)
}
 .notification-summary-card--unread {
   border-color:color-mix(in srgb,var(--brand) 34%,var(--border));
   background:color-mix(in srgb,var(--brand) 7%,var(--surface))
}
 .notification-summary-card--unread strong {
   color:var(--brand)
}
 .notification-toolbar {
   display:flex;
   align-items:center;
   justify-content:space-between;
   gap:18px;
   padding:12px 14px;
   border:1px solid var(--border);
   border-radius:14px;
   background:var(--surface);
   box-shadow:var(--shadow-sm)
}
 .notification-status-tabs {
   display:flex;
   align-items:center;
   gap:5px;
   padding:4px;
   border-radius:11px;
   background:var(--surface-2)
}
 .notification-tab {
   display:inline-flex;
   align-items:center;
   justify-content:center;
   min-height:36px;
   padding:7px 14px;
   border-radius:8px;
   color:var(--muted);
   font-size:13px;
   font-weight:800;
   text-decoration:none
}
 .notification-tab:hover {
   color:var(--text-strong);
   background:var(--surface)
}
 .notification-tab.active {
   color:#fff;
   background:var(--brand);
   box-shadow:0 4px 12px color-mix(in srgb,var(--brand) 22%,transparent)
}
 .notification-kind-filter {
   display:flex;
   align-items:center;
   gap:9px;
   margin:0
}
 .notification-kind-filter label {
   color:var(--muted);
   font-size:13px;
   font-weight:800
}
 .notification-kind-filter select {
   min-width:210px;
   height:40px
}
 .notification-feed {
   display:grid;
   gap:12px
}
 .notification-item {
   position:relative;
   display:grid;
   grid-template-columns:52px minmax(0,1fr) auto;
   gap:16px;
   align-items:start;
   padding:19px 20px;
   border:1px solid var(--border);
   border-radius:16px;
   background:var(--surface);
   box-shadow:var(--shadow-sm);
   transition:border-color .16s ease,background .16s ease,box-shadow .16s ease
}
 .notification-item--unread {
   border-color:color-mix(in srgb,var(--brand) 36%,var(--border));
   background:color-mix(in srgb,var(--brand) 5%,var(--surface));
   box-shadow:0 8px 24px color-mix(in srgb,var(--brand) 9%,transparent)
}
 .notification-item--unread:before {
   content:"";
   position:absolute;
   inset:14px auto 14px 0;
   width:4px;
   border-radius:0 8px 8px 0;
   background:var(--brand)
}
 .notification-item--read {
   opacity:.82
}
 .notification-item--read:hover {
   opacity:1
}
 .notification-icon {
   display:grid;
   place-items:center;
   width:48px;
   height:48px;
   border-radius:14px;
   background:var(--surface-2);
   color:var(--text-strong);
   font-size:20px;
   font-weight:900
}
 .notification-icon--invoice {
   background:rgba(15,138,120,.12);
   color:#0b7163
}
 .notification-icon--payment {
   background:rgba(15,138,120,.12);
   color:#0f766e
}
 .notification-icon--reminder {
   background:rgba(180,83,9,.12);
   color:#b45309
}
 .notification-icon--penalty {
   background:rgba(185,28,28,.1);
   color:#b91c1c
}
 .notification-icon--announcement {
   background:rgba(181,71,8,.12);
   color:#b54708
}
 .notification-content {
   min-width:0
}
 .notification-meta-row {
   display:flex;
   align-items:center;
   justify-content:space-between;
   gap:12px;
   margin-bottom:7px
}
 .notification-labels {
   display:flex;
   align-items:center;
   gap:7px;
   flex-wrap:wrap
}
 .notification-kind-label,.notification-unread-label,.notification-context {
   display:inline-flex;
   align-items:center;
   width:max-content;
   padding:4px 8px;
   border-radius:999px;
   background:var(--surface-2);
   color:var(--muted);
   font-size:10px;
   font-weight:900;
   letter-spacing:.06em;
   text-transform:uppercase
}
 .notification-unread-label {
   background:var(--brand);
   color:#fff
}
 .notification-meta-row time {
   color:var(--muted);
   font-size:12px;
   white-space:nowrap
}
 .notification-content h3 {
   margin:0 0 6px;
   color:var(--text-strong);
   font-size:17px;
   line-height:1.35
}
 .notification-content p {
   margin:0;
   color:var(--muted);
   line-height:1.6;
   overflow-wrap:anywhere
}
 .notification-context {
   margin-top:11px;
   background:color-mix(in srgb,var(--brand) 9%,var(--surface-2));
   color:var(--brand)
}
 .notification-actions {
   display:flex;
   align-items:center;
   justify-content:flex-end;
   gap:8px;
   align-self:center;
   flex-wrap:wrap
}
 .notification-actions form {
   margin:0
}
 .notification-actions .button {
   min-width:102px;
   white-space:nowrap
}
 .notification-empty-state {
   display:grid;
   justify-items:center;
   gap:8px;
   padding:54px 24px;
   border:1px dashed var(--border);
   border-radius:18px;
   background:var(--surface);
   text-align:center
}
 .notification-empty-icon {
   display:grid;
   place-items:center;
   width:58px;
   height:58px;
   margin-bottom:5px;
   border-radius:50%;
   background:color-mix(in srgb,var(--brand) 12%,transparent);
   color:var(--brand);
   font-size:24px;
   font-weight:900
}
 .notification-empty-state h3 {
   margin:0;
   color:var(--text-strong)
}
 .notification-empty-state p {
   max-width:520px;
   margin:0 0 8px;
   color:var(--muted);
   line-height:1.55
}
 @media(max-width:900px) {
   .notification-hero {
     flex-direction:column
  }
   .notification-hero-actions {
     justify-content:flex-start
  }
   .notification-item {
     grid-template-columns:48px minmax(0,1fr)
  }
   .notification-actions {
     grid-column:2;
     justify-content:flex-start
  }
   .notification-toolbar {
     align-items:stretch;
     flex-direction:column
  }
   .notification-kind-filter {
     justify-content:space-between
  }
   .notification-kind-filter select {
     flex:1
  }

}
 @media(max-width:620px) {
   .notification-hero {
     padding:20px
  }
   .notification-hero-actions {
     width:100%;
     align-items:stretch;
     flex-direction:column
  }
   .notification-hero-actions .button,.notification-hero-actions form,.notification-hero-actions form .button {
     width:100%
  }
   .notification-summary {
     grid-template-columns:1fr
  }
   .notification-status-tabs {
     display:grid;
     grid-template-columns:repeat(3,1fr)
  }
   .notification-kind-filter {
     align-items:stretch;
     flex-direction:column
  }
   .notification-kind-filter select {
     width:100%;
     min-width:0
  }
   .notification-item {
     grid-template-columns:42px minmax(0,1fr);
     gap:12px;
     padding:16px
  }
   .notification-icon {
     width:42px;
     height:42px;
     border-radius:12px;
     font-size:18px
  }
   .notification-meta-row {
     align-items:flex-start;
     flex-direction:column;
     gap:6px
  }
   .notification-meta-row time {
     white-space:normal
  }
   .notification-actions {
     grid-column:1/-1;
     display:grid;
     grid-template-columns:repeat(2,minmax(0,1fr))
  }
   .notification-actions form,.notification-actions .button {
     width:100%;
     min-width:0
  }

}

.notification-detail-header {
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:20px;
  padding:22px 24px;
  border:1px solid var(--border);
  border-radius:18px;
  background:var(--surface);
  box-shadow:var(--shadow-sm)
}
.notification-detail-header h2 { margin:4px 0 7px; color:var(--text-strong) }
.notification-detail-header p { margin:0; color:var(--muted) }
.notification-detail-card {
  display:grid;
  gap:20px;
  padding:24px;
  border:1px solid var(--border);
  border-radius:18px;
  background:var(--surface);
  box-shadow:var(--shadow-sm)
}
.notification-detail-card--warning { border-color:color-mix(in srgb,#b45309 32%,var(--border)) }
.notification-detail-card--danger { border-color:color-mix(in srgb,#b91c1c 32%,var(--border)) }
.notification-detail-card--success { border-color:color-mix(in srgb,var(--brand) 32%,var(--border)) }
.notification-detail-meta { display:flex; align-items:center; gap:8px; flex-wrap:wrap }
.notification-detail-meta .notification-context { margin-top:0 }
.notification-detail-body { color:var(--text); font-size:16px; line-height:1.7; overflow-wrap:break-word }
.notification-detail-links { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:12px; margin:0 }
.notification-detail-links div { min-width:0; padding:14px; border:1px solid var(--border); border-radius:12px; background:var(--surface-2) }
.notification-detail-links dt { color:var(--muted); font-size:12px; font-weight:800; text-transform:uppercase }
.notification-detail-links dd { margin:5px 0 0; color:var(--text-strong); font-weight:800; overflow-wrap:break-word }
.notification-detail-actions { display:flex; align-items:center; gap:10px; flex-wrap:wrap }
.notification-detail-actions form { margin:0 }
@media(max-width:760px) {
  .notification-detail-header { flex-direction:column; padding:20px }
  .notification-detail-header .button { width:100% }
  .notification-detail-card { padding:20px }
  .notification-detail-links { grid-template-columns:1fr }
  .notification-detail-actions { align-items:stretch; flex-direction:column }
  .notification-detail-actions form,.notification-detail-actions .button { width:100% }
}
/* ===== END pages/notifications.css ===== */
