@font-face {
  font-family: Inter;
  src: url("/assets/inter-latin.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
:root {
  color-scheme: light;
  --ink: #151515;
  --muted: #626262;
  --line: #e3e3e3;
  --soft: #f4f4f4;
  --radius: 8px;
  font-family: Inter, Arial, sans-serif;
  font-synthesis: none;
  color: var(--ink);
  background: #fff;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
button,
input,
select {
  font: inherit;
}
button,
a,
input,
select {
  -webkit-tap-highlight-color: transparent;
}
button {
  cursor: pointer;
}
button:disabled {
  cursor: wait;
  opacity: 0.55;
}
button,
a {
  touch-action: manipulation;
}
button {
  color: inherit;
}
a {
  color: inherit;
  text-decoration: none;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 2px solid #333;
  outline-offset: 4px;
}
h1,
h2,
p {
  margin: 0;
}
h1,
h2 {
  letter-spacing: -0.035em;
}
h1 {
  font-size: 34px;
  line-height: 1.2;
  font-weight: 650;
}
h2 {
  font-weight: 600;
}
.icon {
  flex-shrink: 0;
  display: block;
}
button .icon {
  width: 20px;
  height: 20px;
}
[hidden] {
  display: none !important;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.skip-link {
  position: fixed;
  left: 16px;
  top: -100px;
  background: #151515;
  color: #fff;
  padding: 12px 20px;
  z-index: 100;
  border-radius: 8px;
}
.skip-link:focus {
  top: 16px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 13px;
  font-size: 26px;
  font-weight: 650;
  letter-spacing: -1px;
  line-height: 1.2;
}
.brand .icon {
  width: 34px;
  height: 34px;
  stroke-width: 1.65;
}
.auth-layout {
  min-height: 100svh;
  display: grid;
  grid-template-columns: 51.5% 48.5%;
  padding: 20px 20px 20px 0;
}
.auth-side {
  display: flex;
  min-width: 0;
  flex-direction: column;
  padding: 16px 48px 18px;
}
.auth-main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 64px 0;
}
.auth-form-wrap {
  width: 100%;
  max-width: 560px;
  margin-top: 16px;
}
.auth-form-wrap h1 {
  font-size: 48px;
  font-weight: 650;
  letter-spacing: -1.9px;
  line-height: 1.15;
}
.intro {
  font-size: 20px;
  line-height: 1.65;
  color: var(--muted);
  margin-top: 16px;
  margin-bottom: 44px;
  max-width: 540px;
}
label {
  display: block;
  font-size: 16px;
  font-weight: 500;
  margin-bottom: 10px;
}
input {
  width: 100%;
  height: 60px;
  border: 1px solid #cecece;
  border-radius: var(--radius);
  padding: 0 18px;
  background: #fff;
  color: var(--ink);
  font-size: 18px;
  transition: border-color 0.15s;
}
input::placeholder {
  color: #818181;
}
input:hover {
  border-color: #a0a0a0;
}
input:focus {
  border-color: #151515;
}
.button {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  gap: 14px;
  min-height: 62px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  font-size: 18px;
  font-weight: 500;
  padding: 14px 42px;
}
.primary {
  background: #151515;
  color: #fff;
  width: 100%;
  margin-top: 22px;
}
.primary:hover:not(:disabled) {
  background: #303030;
}
.primary .icon {
  position: absolute;
  right: 22px;
  width: 21px;
  height: 21px;
}
.auth-note {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.5;
  margin-top: 32px;
}
.auth-note .icon {
  width: 20px;
  height: 20px;
}
.auth-footer {
  font-size: 12px;
  color: #707070;
}
.auth-art {
  position: relative;
  isolation: isolate;
  min-height: calc(100svh - 40px);
  border-radius: 20px;
  overflow: hidden;
  background: #eee;
}
.auth-art img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  z-index: -1;
}
.art-copy {
  position: absolute;
  left: 8%;
  right: 7%;
  bottom: 6%;
}
.art-copy h2 {
  font-size: clamp(28px, 3.05vw, 44px);
  line-height: 1.16;
  font-weight: 650;
  letter-spacing: -1.5px;
}
.art-copy p {
  font-size: clamp(16px, 1.55vw, 22px);
  line-height: 1.5;
  margin-top: 12px;
  color: #555;
}
.text-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 0;
  background: transparent;
  padding: 8px 0;
  min-height: 44px;
  font-size: 14px;
  font-weight: 500;
  text-align: left;
}
.text-button:hover:not(:disabled) {
  text-decoration: underline;
  text-underline-offset: 4px;
}
.back-button {
  margin-bottom: 30px;
  color: var(--muted);
}
.back-button .icon {
  width: 18px;
  height: 18px;
}
.code-intro {
  overflow-wrap: anywhere;
  font-size: 17px;
  margin-bottom: 28px;
}
.code-intro strong {
  font-weight: 500;
  color: #333;
}
#code {
  font-size: 28px;
  font-weight: 500;
  letter-spacing: 0.5em;
  height: 64px;
  text-align: center;
  padding-left: 30px;
}
.field-hint {
  font-size: 13px;
  color: var(--muted);
  margin-top: 10px;
  line-height: 1.5;
}
.resend-row {
  margin-top: 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 13px;
  color: var(--muted);
}
.resend-row button {
  color: var(--ink);
}
.form-error {
  font-size: 14px;
  line-height: 1.5;
  margin-top: 12px;
  padding: 12px 14px;
  border: 1px solid #bbb;
  border-radius: 6px;
  background: var(--soft);
  color: #222;
}
.workspace-layout {
  min-height: 100svh;
  display: grid;
  grid-template-columns: 248px minmax(0, 1fr);
}
.sidebar {
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 0;
  height: 100svh;
  border-right: 1px solid var(--line);
  background: #fff;
}
.sidebar-brand {
  height: 80px;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.sidebar .brand {
  font-size: 23px;
  gap: 12px;
}
.sidebar .brand .icon {
  width: 32px;
  height: 32px;
}
.sidebar nav {
  padding: 22px 16px;
}
.nav-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.085em;
  font-weight: 500;
  color: var(--muted);
  margin: 0 8px 10px;
}
.nav-item {
  display: flex;
  gap: 14px;
  align-items: center;
  padding: 12px 16px;
  min-height: 46px;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 500;
}
.nav-item .icon {
  width: 21px;
  height: 21px;
}
.nav-item.active {
  background: #f1f1f1;
}
.sidebar-account {
  margin-top: auto;
  border-top: 1px solid var(--line);
  padding: 24px 24px 20px;
}
.account-summary {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}
.avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #ededed;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 500;
  flex-shrink: 0;
}
.account-name {
  display: block;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.4;
  overflow-wrap: anywhere;
}
.account-role {
  display: block;
  color: var(--muted);
  font-size: 12px;
  margin-top: 3px;
}
.sign-out {
  justify-content: flex-start;
  width: 100%;
  margin-top: 18px;
  color: #464646;
  font-size: 14px;
  gap: 14px;
}
.sign-out .icon {
  width: 22px;
  height: 22px;
}
.workspace-stage {
  min-width: 0;
}
.topbar {
  height: 80px;
  border-bottom: 1px solid var(--line);
  padding: 0 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.topbar-left {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 14px;
  color: var(--muted);
}
.agency-picker {
  display: flex;
  align-items: center;
  position: relative;
  border: 1px solid #d9d9d9;
  border-radius: 8px;
  min-width: 196px;
  max-width: 360px;
  height: 44px;
}
.agency-picker > .icon:first-child {
  position: absolute;
  left: 14px;
  width: 20px;
  height: 20px;
  pointer-events: none;
  color: #555;
}
.agency-picker > .icon:last-child {
  position: absolute;
  right: 12px;
  width: 16px;
  height: 16px;
  pointer-events: none;
  color: #555;
}
.agency-picker select {
  appearance: none;
  border: 0;
  border-radius: 8px;
  background: transparent;
  width: 100%;
  height: 100%;
  padding: 0 36px 0 46px;
  cursor: pointer;
  font-size: 14px;
  text-overflow: ellipsis;
  color: var(--ink);
}
.agency-context {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  max-width: 60%;
  min-width: 0;
}
.agency-context span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.agency-context .icon {
  width: 20px;
  height: 20px;
  color: #666;
}
.workspace-main {
  padding: 38px 32px 48px;
}
.section-description {
  font-size: 16px;
  line-height: 1.6;
  color: var(--muted);
  margin-top: 8px;
}
.empty-panel {
  border: 1px solid var(--line);
  border-radius: 12px;
  min-height: 470px;
  margin-top: 32px;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 40px 24px;
}
.empty-content > .icon {
  width: 48px;
  height: 48px;
  color: #adb0b3;
  stroke-width: 1.6;
  margin: 0 auto 26px;
}
.empty-content h2 {
  font-size: 20px;
  letter-spacing: -0.4px;
  font-weight: 550;
}
.empty-content p {
  font-size: 15px;
  line-height: 1.6;
  color: var(--muted);
  margin-top: 12px;
}
.workspace-error {
  margin-top: 28px;
  border: 1px solid #bbb;
  border-radius: 8px;
  padding: 16px;
  background: var(--soft);
  font-size: 14px;
  line-height: 1.6;
}
.workspace-error button {
  padding-bottom: 0;
}
.icon-button {
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 8px;
}
.icon-button .icon {
  width: 20px;
  height: 20px;
}
.mobile-only {
  display: none;
}
.noscript-notice {
  position: fixed;
  bottom: 16px;
  left: 16px;
  right: 16px;
  border: 1px solid #bbb;
  background: #fff;
  padding: 20px;
  border-radius: 8px;
  z-index: 99;
}
.is-loading {
  opacity: 0.5;
}
.sidebar-backdrop {
  display: none;
}
@media (min-width: 1600px) {
  .auth-side {
    padding-left: 60px;
    padding-right: 60px;
  }
  .auth-form-wrap {
    max-width: 560px;
  }
  .auth-form-wrap h1 {
    font-size: 50px;
  }
  .intro {
    font-size: 20px;
  }
}
@media (max-width: 1100px) {
  .auth-side {
    padding-left: 32px;
    padding-right: 32px;
  }
  .auth-form-wrap h1 {
    font-size: 38px;
  }
  .intro {
    font-size: 16px;
  }
  .auth-note {
    font-size: 12px;
  }
  .art-copy h2 {
    font-size: 31px;
  }
  .art-copy p {
    font-size: 17px;
  }
  .workspace-layout {
    grid-template-columns: 224px minmax(0, 1fr);
  }
  .sidebar-brand {
    padding: 0 20px;
  }
  .sidebar-account {
    padding: 20px;
  }
  .workspace-main {
    padding: 32px 24px;
  }
  .topbar {
    padding: 0 24px;
  }
}
@media (max-width: 760px) {
  .auth-layout {
    display: block;
    padding: 0;
    min-height: 100svh;
  }
  .auth-side {
    min-height: 100svh;
    padding: 28px 24px 24px;
  }
  .auth-side .brand {
    font-size: 24px;
  }
  .auth-side .brand .icon {
    width: 30px;
    height: 30px;
  }
  .auth-main {
    padding: 52px 0 72px;
  }
  .auth-form-wrap {
    max-width: 440px;
    margin: 0;
  }
  .auth-form-wrap h1 {
    font-size: 36px;
    letter-spacing: -1.4px;
  }
  .intro {
    font-size: 16px;
    margin-bottom: 32px;
    line-height: 1.6;
  }
  .auth-art {
    display: none;
  }
  .auth-note {
    font-size: 13px;
    align-items: flex-start;
    gap: 10px;
  }
  .auth-footer {
    font-size: 11px;
  }
  .button {
    font-size: 16px;
  }
  .resend-row {
    flex-wrap: wrap;
  }
  .workspace-layout {
    display: block;
  }
  .sidebar {
    position: fixed;
    z-index: 30;
    left: 0;
    top: 0;
    width: 280px;
    max-width: calc(100vw - 48px);
    transform: translateX(-100%);
    visibility: hidden;
    transition:
      transform 0.18s ease,
      visibility 0.18s;
  }
  .sidebar.open {
    transform: translateX(0);
    visibility: visible;
  }
  .sidebar-brand {
    height: 76px;
    padding: 0 20px;
  }
  .sidebar-brand .icon-button {
    border: 0;
  }
  .sidebar-backdrop:not([hidden]) {
    display: block;
    position: fixed;
    inset: 0;
    border: 0;
    background: #0005;
    z-index: 25;
  }
  .mobile-only {
    display: flex;
  }
  .topbar {
    height: 76px;
    padding: 0 20px;
    gap: 12px;
  }
  .topbar-left > span {
    display: none;
  }
  .agency-picker {
    min-width: 180px;
    max-width: calc(100vw - 96px);
  }
  .agency-context {
    max-width: calc(100vw - 104px);
  }
  .workspace-main {
    padding: 30px 20px;
  }
  .workspace-main h1 {
    font-size: 30px;
  }
  .section-description {
    font-size: 15px;
  }
  .empty-panel {
    margin-top: 28px;
    min-height: 390px;
    padding: 32px 20px;
  }
  .empty-content h2 {
    font-size: 19px;
  }
  .empty-content p {
    font-size: 14px;
  }
  .sidebar-account {
    padding: 24px;
  }
  .sidebar .brand {
    font-size: 23px;
  }
}
@media (max-width: 360px) {
  .auth-side {
    padding: 24px 20px;
  }
  .auth-form-wrap h1 {
    font-size: 32px;
  }
  .auth-note {
    font-size: 12px;
  }
  .button {
    font-size: 15px;
  }
  .workspace-main {
    padding: 28px 16px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *:before,
  *:after {
    scroll-behavior: auto !important;
    transition: none !important;
    animation: none !important;
  }
}

/* Compact workspace scale; touch controls retain a 44px minimum on mobile. */
body {
  font-size: 13px;
  line-height: 1.5;
}
textarea {
  font: inherit;
  resize: vertical;
}
textarea:focus-visible,
summary:focus-visible {
  outline: 2px solid #333;
  outline-offset: 3px;
}
.muted {
  color: var(--muted);
}
.workspace-layout {
  grid-template-columns: 200px minmax(0, 1fr);
}
.sidebar {
  background: #fafafa;
}
.sidebar-brand {
  height: 64px;
  padding: 0 18px;
}
.sidebar .brand {
  font-size: 21px;
  gap: 9px;
}
.sidebar .brand .icon {
  width: 28px;
  height: 28px;
}
.sidebar nav {
  padding: 20px 12px;
}
.nav-item {
  min-height: 38px;
  padding: 8px 12px;
  font-size: 13px;
  gap: 10px;
  margin-bottom: 4px;
  border-radius: 6px;
}
.nav-item .icon {
  width: 18px;
  height: 18px;
}
.nav-label {
  font-size: 10px;
}
.sidebar-account {
  padding: 18px 16px;
}
.account-summary {
  gap: 9px;
}
.account-name {
  font-size: 12px;
}
.account-role {
  font-size: 11px;
}
.avatar {
  height: 32px;
  width: 32px;
  font-size: 11px;
}
.sign-out {
  font-size: 12px;
  margin-top: 12px;
  min-height: 36px;
}
.sign-out .icon {
  width: 18px;
  height: 18px;
}
.topbar {
  height: 64px;
  padding: 0 24px;
}
.topbar-left,
.agency-context {
  font-size: 12px;
}
.agency-picker {
  height: 36px;
  min-width: 180px;
  border-radius: 6px;
}
.agency-picker select {
  font-size: 12px;
}
.agency-picker > .icon:first-child {
  height: 17px;
  width: 17px;
  left: 12px;
}
.agency-picker select {
  padding-left: 38px;
}
.workspace-main {
  padding: 28px 24px 40px;
}
.workspace-main h1 {
  font-size: 27px;
  letter-spacing: -0.9px;
}
.section-description {
  font-size: 13px;
  margin-top: 5px;
}
.page-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
}
.small-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 34px;
  padding: 7px 12px;
  border: 1px solid #d7d7d7;
  border-radius: 6px;
  background: #fff;
  white-space: nowrap;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.4;
}
.small-button:hover:not(:disabled) {
  background: #f1f1f1;
}
.small-button .icon {
  height: 16px;
  width: 16px;
}
.small-button.dark {
  background: #191919;
  border-color: #191919;
  color: #fff;
}
.small-button.dark:hover:not(:disabled) {
  background: #353535;
}
.empty-panel {
  margin-top: 0;
  min-height: 360px;
  border-radius: 8px;
}
.empty-content > .icon {
  width: 40px;
  height: 40px;
  margin-bottom: 18px;
  color: #969a9e;
}
.empty-content h2 {
  font-size: 16px;
}
.empty-content p {
  font-size: 13px;
  margin-top: 8px;
}
.text-button {
  font-size: 12px;
  min-height: 34px;
}
.workspace-error {
  margin: 0 0 20px;
  font-size: 13px;
}
.register {
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
}
.register-row {
  display: grid;
  grid-template-columns: minmax(160px, 1.1fr) minmax(100px, 1fr) auto;
  gap: 20px;
  padding: 16px 18px;
  align-items: center;
  border-top: 1px solid var(--line);
  font-size: 13px;
}
.workspace-layout[data-section="users"] .register-row {
  grid-template-columns:
    minmax(170px, 1.3fr) minmax(100px, 1fr) minmax(105px, 0.6fr)
    auto;
}
.register-head {
  border: 0;
  background: #fafafa;
  font-size: 11px;
  color: var(--muted);
  padding-top: 11px;
  padding-bottom: 11px;
}
.register-row strong {
  font-weight: 550;
}
.row-secondary {
  display: block;
  font-size: 12px;
  color: var(--muted);
  margin-top: 3px;
  overflow-wrap: anywhere;
}
.row-arrow {
  color: #777;
}
.record-link {
  font-weight: 550;
  text-decoration: underline;
  text-underline-offset: 4px;
}
.row-agency,
.row-role {
  overflow-wrap: anywhere;
}
.impersonation-banner {
  background: #242424;
  color: #fff;
  padding: 10px 24px;
  display: flex;
  gap: 12px;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
}
.impersonation-banner > span {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  align-items: center;
}
.impersonation-banner .icon {
  height: 16px;
  width: 16px;
}
.acting-note {
  color: #d1d1d1;
  margin-left: 6px;
  font-size: 11px;
}
.impersonation-banner button {
  color: #171717;
  flex-shrink: 0;
}
.record-main {
  padding: 0;
}
.record-main .workspace-error {
  margin: 16px 24px;
}
.record-heading {
  padding: 22px 24px 24px;
}
.back-link {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 12px;
  min-height: 28px;
}
.back-link .icon {
  width: 15px;
  height: 15px;
}
.record-reference {
  font-size: 13px;
  color: #777;
  font-weight: 400;
  letter-spacing: 0;
  margin-left: 8px;
  vertical-align: middle;
}
.record-layout {
  display: grid;
  grid-template-columns: 450px minmax(0, 1fr);
  border-top: 1px solid var(--line);
  min-height: calc(100svh - 183px);
}
.record-overview {
  border-right: 1px solid var(--line);
  padding: 24px;
}
.record-overview summary {
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.3px;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.record-overview summary::-webkit-details-marker {
  display: none;
}
.record-overview summary .icon {
  display: none;
  width: 17px;
  height: 17px;
}
.overview-body {
  padding-top: 20px;
}
.record-content {
  min-width: 0;
  padding: 0 24px 28px;
}
.record-tabs {
  display: flex;
  gap: 20px;
  overflow-x: auto;
  border-bottom: 1px solid var(--line);
  scrollbar-width: thin;
  overscroll-behavior-x: contain;
}
.record-tabs button {
  flex-shrink: 0;
  border: 0;
  border-bottom: 2px solid transparent;
  background: #fff;
  padding: 19px 0 15px;
  font-size: 12px;
  color: #5e5e5e;
  white-space: nowrap;
}
.record-tabs button[aria-selected="true"] {
  border-bottom-color: #191919;
  color: #191919;
  font-weight: 600;
}
.record-tabs button:focus-visible {
  outline-offset: -3px;
}
.panel-title {
  font-size: 20px;
  margin-top: 24px;
  letter-spacing: -0.5px;
  font-weight: 600;
}
.panel-description {
  font-size: 13px;
  color: var(--muted);
  margin-top: 3px;
}
.record-content .empty-panel {
  border: 0;
  min-height: 300px;
  padding: 32px 12px;
}
.record-content #record-panel {
  outline-offset: 4px;
}
.comments-list {
  margin: 24px 0;
}
.comment-thread + .comment-thread {
  border-top: 1px solid var(--line);
  margin-top: 18px;
  padding-top: 18px;
}
.comment {
  padding: 0 0 12px;
  min-width: 0;
}
.comment.is-reply {
  margin-left: 24px;
  border-left: 1px solid var(--line);
  padding-left: 16px;
  margin-top: 12px;
}
.comment-top > div {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 10px;
}
.comment-top strong {
  font-size: 13px;
  font-weight: 600;
}
.comment time,
.activity-heading time {
  font-size: 11px;
  color: var(--muted);
  font-weight: 400;
}
.comment-body {
  margin: 9px 0 8px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font-size: 13px;
  line-height: 1.7;
}
.acting-author {
  font-size: 11px;
  color: var(--muted);
  margin-top: 3px;
}
.comment-actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  align-items: center;
}
.reaction {
  border: 1px solid transparent;
  border-radius: 16px;
  background: #f5f5f5;
  padding: 4px 8px;
  font-size: 12px;
  min-height: 28px;
}
.reaction.selected {
  border-color: #888;
  background: #eaeaea;
}
.comment-actions .text-button {
  margin-left: 6px;
  min-height: 28px;
}
.comment-composer {
  position: relative;
  border: 1px solid #ccc;
  border-radius: 8px;
  padding: 12px;
  background: #fff;
}
.comment-composer textarea {
  width: 100%;
  border: 0;
  background: #fff;
  padding: 0;
  line-height: 1.6;
  min-height: 76px;
  font-size: 13px;
  color: var(--ink);
}
.comment-composer textarea:focus {
  outline-offset: 5px;
}
.composer-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
}
.composer-footer .text-button {
  color: var(--muted);
}
.reply-context {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  background: #f5f5f5;
  padding: 5px 8px;
  border-radius: 4px;
  margin-bottom: 12px;
  font-size: 12px;
}
.mention-tags {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin: 8px 0;
}
.mention-tag {
  border: 1px solid #ddd;
  border-radius: 4px;
  background: #f6f6f6;
  padding: 3px 7px;
  font-size: 11px;
  overflow-wrap: anywhere;
  max-width: 100%;
}
.mention-suggestions {
  border: 1px solid #ddd;
  border-radius: 6px;
  padding: 4px;
  background: white;
  max-height: 200px;
  overflow: auto;
  margin-top: 4px;
  box-shadow: 0 4px 12px #0000000a;
}
.mention-suggestions p {
  padding: 10px;
}
.mention-option {
  display: block;
  width: 100%;
  background: #fff;
  border: 0;
  text-align: left;
  padding: 9px 12px;
  font-size: 13px;
  border-radius: 4px;
}
.mention-option:hover,
.mention-option:focus {
  background: #f1f1f1;
}
.activity-list {
  list-style: none;
  padding: 0;
  margin: 24px 0;
}
.activity-item {
  position: relative;
  padding: 0 0 24px 22px;
  border-left: 1px solid #ddd;
  margin-left: 4px;
}
.activity-item:before {
  content: "";
  position: absolute;
  left: -4px;
  top: 6px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #9b9b9b;
}
.activity-item:last-child {
  border-color: transparent;
}
.activity-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.activity-heading strong {
  font-size: 13px;
  font-weight: 550;
}
.activity-author {
  font-size: 12px;
  color: var(--muted);
  margin: 3px 0 10px;
}
.change-details {
  margin: 0;
  background: #f7f7f7;
  border-radius: 6px;
  padding: 10px 12px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 5px 12px;
  font-size: 12px;
}
.change-details dt {
  color: var(--muted);
}
.change-details dd {
  margin: 0;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
dialog {
  width: 460px;
  max-width: calc(100vw - 32px);
  max-height: calc(100svh - 32px);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 24px;
  color: var(--ink);
  overflow: auto;
  box-shadow: 0 24px 90px #0002;
}
dialog::backdrop {
  background: #0005;
}
.dialog-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}
.dialog-heading h2 {
  font-size: 20px;
}
.dialog-heading .icon-button {
  display: flex;
  border: 0;
  width: 32px;
  height: 32px;
  flex-shrink: 0;
}
.form-field {
  margin-top: 16px;
}
.dialog-form label {
  font-size: 12px;
  margin-bottom: 6px;
}
.dialog-form input,
.dialog-form select {
  width: 100%;
  height: 38px;
  font-size: 13px;
  border: 1px solid #ccc;
  border-radius: 6px;
  padding: 0 10px;
  background: #fff;
  color: var(--ink);
}
.dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 24px;
}
.dialog-form .field-hint {
  font-size: 12px;
  margin-top: 12px;
}
.dialog-form .text-button {
  margin-top: 4px;
}
.auth-form-wrap {
  max-width: 440px;
}
.auth-form-wrap h1 {
  font-size: 38px;
  letter-spacing: -1.4px;
}
.intro {
  font-size: 16px;
  margin-top: 14px;
  margin-bottom: 32px;
}
.auth-side label {
  font-size: 13px;
  margin-bottom: 8px;
}
.auth-side input {
  height: 48px;
  font-size: 16px;
  padding: 0 14px;
}
.auth-side .button {
  min-height: 48px;
  font-size: 14px;
  margin-top: 18px;
  padding: 12px 38px;
}
.auth-note {
  font-size: 12px;
  margin-top: 24px;
}
.auth-note .icon {
  width: 17px;
  height: 17px;
}
#code {
  height: 52px;
  font-size: 24px;
}
.code-intro {
  font-size: 14px;
}
.auth-side .brand {
  font-size: 23px;
}
.auth-side .brand .icon {
  width: 29px;
  height: 29px;
}
@media (max-width: 1300px) and (min-width: 1101px) {
  .record-content {
    padding-left: 18px;
    padding-right: 18px;
  }
  .record-tabs {
    gap: 16px;
  }
}
@media (max-width: 1100px) {
  .record-layout {
    display: block;
  }
  .record-overview {
    border-right: 0;
    border-bottom: 1px solid var(--line);
    padding: 0 24px;
  }
  .record-overview summary {
    padding: 16px 0;
    cursor: pointer;
    font-size: 15px;
    min-height: 52px;
  }
  .record-overview summary .icon {
    display: block;
  }
  .record-overview[open] summary .icon {
    transform: rotate(180deg);
  }
  .overview-body {
    padding: 0 0 20px;
  }
  .record-content {
    padding-bottom: 32px;
  }
  .record-tabs {
    gap: 24px;
  }
}
@media (max-width: 760px) {
  .workspace-layout {
    display: block;
  }
  .sidebar-brand {
    height: 64px;
  }
  .nav-item {
    min-height: 44px;
    font-size: 14px;
  }
  .sidebar-account {
    padding: 20px;
  }
  .account-name {
    font-size: 13px;
  }
  .sign-out {
    min-height: 44px;
    font-size: 13px;
  }
  .topbar {
    height: 64px;
    padding: 0 16px;
  }
  .agency-picker {
    height: 44px;
    max-width: calc(100vw - 92px);
    min-width: 160px;
  }
  .agency-picker select {
    font-size: 13px;
  }
  .workspace-main {
    padding: 24px 16px;
  }
  .workspace-main h1 {
    font-size: 25px;
  }
  .page-heading {
    gap: 10px;
    align-items: flex-start;
  }
  .small-button,
  .text-button {
    min-height: 44px;
  }
  .small-button {
    padding: 9px 12px;
    font-size: 12px;
  }
  .section-description {
    font-size: 12px;
  }
  .page-heading .small-button {
    flex-shrink: 0;
  }
  .empty-panel {
    min-height: 330px;
  }
  .register-head {
    display: none;
  }
  .register-row,
  .workspace-layout[data-section="users"] .register-row {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 7px 12px;
    padding: 16px;
  }
  .register-row:first-of-type {
    border: 0;
  }
  .register-row .row-agency {
    grid-column: 1;
    font-size: 12px;
    color: var(--muted);
  }
  .register-row .row-role {
    grid-column: 1;
    font-size: 12px;
  }
  .register-row button,
  .register-row .row-arrow {
    grid-column: 2;
    grid-row: 1/4;
  }
  .register-row .record-link {
    min-height: 32px;
    display: flex;
    align-items: center;
    font-size: 13px;
  }
  .impersonation-banner {
    padding: 10px 16px;
    align-items: flex-start;
    flex-wrap: wrap;
    font-size: 12px;
  }
  .impersonation-banner .acting-note {
    display: block;
    width: 100%;
    margin-left: 0;
  }
  .record-main {
    padding: 0;
  }
  .record-heading {
    padding: 16px 16px 20px;
  }
  .back-link {
    min-height: 34px;
    margin-bottom: 8px;
  }
  .record-reference {
    font-size: 12px;
    margin-left: 4px;
  }
  .record-overview {
    padding: 0 16px;
  }
  .record-content {
    padding: 0 16px 24px;
  }
  .record-tabs {
    gap: 24px;
  }
  .record-tabs button {
    font-size: 13px;
    padding-top: 17px;
    padding-bottom: 15px;
    min-height: 48px;
  }
  .panel-title {
    font-size: 20px;
    margin-top: 22px;
  }
  .record-content .empty-panel {
    min-height: 270px;
  }
  .panel-description {
    font-size: 12px;
  }
  .comment-body {
    font-size: 14px;
  }
  .comment.is-reply {
    margin-left: 12px;
    padding-left: 12px;
  }
  .reaction {
    min-width: 44px;
    min-height: 44px;
    padding: 8px;
    font-size: 14px;
  }
  .comment-actions {
    gap: 4px;
  }
  .comment-actions .text-button {
    min-height: 44px;
  }
  .comment-composer textarea {
    font-size: 16px;
    min-height: 100px;
  }
  .mention-tag {
    min-height: 30px;
    display: inline-flex;
    align-items: center;
  }
  .mention-option {
    min-height: 44px;
    font-size: 14px;
  }
  .change-details {
    grid-template-columns: 1fr;
    gap: 2px;
  }
  .change-details dd + dt {
    margin-top: 7px;
  }
  .activity-heading {
    gap: 3px;
  }
  .activity-heading time {
    width: 100%;
  }
  .dialog-form input,
  .dialog-form select {
    font-size: 16px;
    height: 44px;
  }
  .dialog-form label {
    font-size: 13px;
  }
  .dialog-heading .icon-button {
    width: 44px;
    height: 44px;
  }
  dialog {
    padding: 20px;
  }
  .auth-side .text-button {
    min-height: 44px;
  }
  .auth-form-wrap h1 {
    font-size: 34px;
  }
  .auth-side .button {
    font-size: 15px;
    min-height: 48px;
  }
  .auth-note {
    font-size: 12px;
  }
  .composer-footer {
    align-items: center;
  }
  .composer-footer .text-button {
    font-size: 11px;
  }
}
/* Tenancy register and Sign Up */
.nav-children {
  margin: 2px 0 18px 21px;
  padding-left: 15px;
  border-left: 1px solid #dedede;
  display: grid;
  gap: 2px;
}
.nav-child {
  font-size: 12px;
  color: #626262;
  padding: 7px 10px;
  border-radius: 5px;
  min-height: 32px;
  display: flex;
  align-items: center;
}
.nav-child.active {
  color: #161616;
  background: #ececec;
  font-weight: 550;
}
.nav-child:hover {
  background: #f0f0f0;
}
.table-toolbar {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 16px;
  flex-wrap: wrap;
}
.table-search {
  height: 38px;
  max-width: 340px;
  font-size: 13px;
  border-radius: 6px;
  padding: 0 12px;
}
.table-count {
  font-size: 12px;
  color: #686868;
  margin-left: auto;
}
.table-filters {
  position: relative;
}
.table-filters summary {
  list-style: none;
  cursor: pointer;
  min-width: 76px;
}
.table-filters summary::-webkit-details-marker {
  display: none;
}
.filter-popover {
  position: absolute;
  left: 0;
  top: 44px;
  width: 240px;
  padding: 16px;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 8px;
  box-shadow: 0 8px 30px #0001;
  z-index: 6;
}
.filter-popover label {
  font-size: 12px;
  margin-bottom: 12px;
}
.filter-popover select {
  display: block;
  width: 100%;
  height: 36px;
  margin-top: 6px;
  font-size: 13px;
  border: 1px solid #ccc;
  border-radius: 5px;
  background: #fff;
  padding: 0 8px;
}
.table-scroll {
  position: relative;
  overflow: auto;
  max-height: calc(100svh - 255px);
  min-height: 220px;
  border: 1px solid var(--line);
  border-radius: 8px;
  overscroll-behavior: contain;
  scrollbar-width: thin;
}
.tenancy-table {
  border-collapse: separate;
  border-spacing: 0;
  width: 100%;
  font-size: 13px;
  white-space: nowrap;
}
.tenancy-table caption {
  text-align: left;
}
.tenancy-table thead {
  position: sticky;
  top: 0;
  z-index: 2;
}
.tenancy-table th {
  font-weight: 500;
  text-align: left;
  background: #f8f8f8;
  border-bottom: 1px solid #ddd;
  min-width: 120px;
}
.tenancy-table th:first-child {
  min-width: 200px;
}
.tenancy-table td {
  padding: 14px 16px;
  border-bottom: 1px solid #ededed;
  height: 53px;
  max-width: 340px;
  overflow: hidden;
  text-overflow: ellipsis;
}
.tenancy-table tr:last-child td {
  border-bottom: 0;
}
.tenancy-table tbody tr:hover {
  background: #fafafa;
}
.sort-button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  width: 100%;
  padding: 12px 16px;
  min-height: 42px;
  border: 0;
  background: transparent;
  font-size: 12px;
  text-align: left;
  white-space: nowrap;
}
.sort-indicator {
  color: #929292;
  font-size: 13px;
}
th[aria-sort="ascending"] .sort-indicator,
th[aria-sort="descending"] .sort-indicator {
  color: #171717;
}
.tenancy-name {
  font-weight: 550;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.tenancy-name:hover {
  color: #555;
}
.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  border-radius: 5px;
  padding: 3px 8px;
  font-size: 11px;
  font-weight: 550;
  background: #f0f0f0;
  color: #505050;
}
.badge-approved {
  color: #345bb0;
  background: #edf2ff;
}
.badge-current {
  color: #276c47;
  background: #eaf5ee;
}
.badge-vacating {
  color: #916015;
  background: #fff3da;
}
.badge-archived {
  color: #63636b;
  background: #eeeef1;
}
.badge-weekly {
  color: #496296;
  background: #edf1fa;
}
.badge-fortnightly {
  color: #78549d;
  background: #f3edf9;
}
.badge-monthly {
  color: #377573;
  background: #eaf4f3;
}
.table-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
  font-size: 12px;
}
.table-sentinel {
  height: 1px;
}
.tenancy-table .table-empty {
  text-align: center;
  height: 200px;
  font-size: 13px;
  color: #666;
}
.signup-table th {
  min-width: 160px;
}
.signup-table th:first-child,
.signup-table td:first-child {
  position: sticky;
  left: 0;
  z-index: 1;
  background: #fff;
  border-right: 1px solid #eee;
  max-width: 240px;
  min-width: 180px;
}
.signup-table th:first-child {
  background: #f8f8f8;
  z-index: 3;
}
.file-count {
  text-decoration: underline;
  text-underline-offset: 3px;
}
.person-value {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  min-width: 0;
  max-width: 100%;
  font-size: 12px;
}
.person-value > span:last-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.person-photo {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  background: #ededed;
}
.person-initials {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #555;
  font-size: 10px;
}
.tenancy-form {
  margin-top: 22px;
}
.record-overview .tenancy-form {
  margin-top: 0;
}
.tenancy-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px 18px;
}
.record-overview .tenancy-form-grid {
  grid-template-columns: 1fr;
}
.tenancy-field {
  min-width: 0;
}
.tenancy-field label,
.field-label {
  display: block;
  font-size: 12px;
  font-weight: 500;
  margin-bottom: 7px;
  line-height: 1.5;
}
.tenancy-field input:not([type="file"]),
.tenancy-field select {
  width: 100%;
  height: 38px;
  padding: 0 10px;
  border: 1px solid #d3d3d3;
  border-radius: 6px;
  background: #fff;
  font-size: 13px;
  color: #202020;
  min-width: 0;
}
.tenancy-field input[readonly] {
  background: #f6f6f6;
  color: #626262;
}
.tenancy-field select {
  padding-right: 24px;
}
.unit-input {
  position: relative;
}
.unit-input input {
  padding-right: 52px !important;
}
.input-unit {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: #777;
  font-size: 11px;
  pointer-events: none;
}
.form-section-title {
  grid-column: 1/-1;
  border-top: 1px solid #e0e0e0;
  margin: 10px 0 0;
  padding-top: 24px;
  font-size: 17px;
  letter-spacing: -0.3px;
  font-weight: 600;
}
.form-save-row {
  margin-top: 22px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}
.save-status {
  font-size: 12px;
  color: #555;
}
.tenancy-form .form-error {
  margin-top: 16px;
}
.user-picker {
  position: relative;
}
.user-select {
  width: 100%;
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding: 4px 10px;
  border: 1px solid #d3d3d3;
  border-radius: 6px;
  background: #fff;
  font-size: 13px;
  text-align: left;
}
.user-select:after {
  content: "⌄";
  margin-left: auto;
  padding-left: 6px;
  color: #666;
}
.user-menu {
  position: absolute;
  left: 0;
  right: 0;
  top: 44px;
  z-index: 5;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 7px;
  box-shadow: 0 6px 20px #0001;
  padding: 8px;
  max-height: 280px;
  overflow: auto;
}
.user-menu input {
  margin-bottom: 6px;
}
.user-option {
  display: flex;
  width: 100%;
  padding: 8px;
  border: 0;
  background: white;
  font-size: 12px;
  text-align: left;
  border-radius: 4px;
}
.user-option:hover {
  background: #f3f3f3;
}
.attachment-field {
  grid-column: 1/-1;
}
.attachment-list {
  display: grid;
  gap: 6px;
  margin-bottom: 8px;
}
.attachment-row {
  display: flex;
  gap: 10px;
  align-items: center;
  border: 1px solid #e4e4e4;
  border-radius: 6px;
  padding: 6px 10px;
  min-width: 0;
}
.attachment-name {
  font-size: 12px;
  text-decoration: underline;
  overflow-wrap: anywhere;
  min-width: 0;
}
.attachment-row .text-button {
  margin-left: auto;
  flex-shrink: 0;
}
.file-size {
  font-size: 11px;
  color: #777;
  flex-shrink: 0;
}
.upload-control,
.photo-control {
  position: relative;
  overflow: hidden;
  cursor: pointer;
}
.tenancy-field .upload-control {
  display: inline-flex;
  border: 1px dashed #bcbcbc;
  border-radius: 6px;
  padding: 9px 14px;
  font-size: 12px;
  margin: 0;
}
.upload-control input,
.photo-control input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  width: 100%;
  height: 100%;
  padding: 0;
}
.upload-control:focus-within,
.photo-control:focus-within {
  outline: 2px solid #333;
  outline-offset: 3px;
}
.user-row-controls {
  display: flex;
  gap: 8px;
  align-items: center;
}
.photo-control {
  margin: 0;
  font-size: 12px;
  font-weight: 500;
}
.agency-settings-form {
  max-width: 540px;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  padding: 24px;
}
.agency-settings-form h2 {
  font-size: 18px;
  margin: 0 0 24px;
}
.agency-settings-form label {
  font-size: 13px;
  margin-bottom: 7px;
}
.agency-settings-form input {
  height: 40px;
  font-size: 14px;
  max-width: 180px;
}
.agency-settings-form .small-button {
  margin-top: 20px;
}
.agency-settings-form .save-status {
  margin-top: 12px;
}
.create-tenancy-fields {
  display: grid;
  gap: 14px;
  margin-top: 16px;
}
.create-tenancy-fields label {
  font-size: 12px;
}
.overview-body {
  padding-top: 20px;
}
.record-heading h1 {
  overflow-wrap: anywhere;
}
@media (max-width: 1300px) and (min-width: 1101px) {
  .tenancy-form-grid {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 760px) {
  .nav-child {
    min-height: 40px;
    font-size: 13px;
  }
  .table-search {
    height: 44px;
    max-width: none;
    flex: 1;
    min-width: 180px;
    font-size: 16px;
  }
  .table-toolbar {
    gap: 10px;
  }
  .table-count {
    width: 100%;
    margin-left: 0;
  }
  .table-filters summary {
    min-height: 44px;
  }
  .filter-popover {
    left: auto;
    right: 0;
    top: 50px;
    max-width: calc(100vw - 32px);
  }
  .filter-popover select {
    height: 44px;
    font-size: 16px;
  }
  .table-scroll {
    max-height: calc(100svh - 285px);
    min-height: 240px;
  }
  .tenancy-table td {
    padding: 12px;
    font-size: 13px;
  }
  .sort-button {
    padding: 12px;
    min-height: 46px;
    font-size: 12px;
  }
  .tenancy-form-grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }
  .tenancy-field input:not([type="file"]),
  .tenancy-field select {
    height: 44px;
    font-size: 16px;
  }
  .tenancy-field label,
  .field-label {
    font-size: 13px;
  }
  .user-select {
    min-height: 44px;
    font-size: 14px;
  }
  .user-menu {
    top: 50px;
  }
  .user-option {
    min-height: 44px;
  }
  .person-value {
    font-size: 13px;
  }
  .attachment-row {
    flex-wrap: wrap;
    gap: 4px 10px;
  }
  .attachment-name {
    flex: 1 1 65%;
  }
  .file-size {
    font-size: 11px;
  }
  .tenancy-field .upload-control {
    min-height: 44px;
    align-items: center;
  }
  .user-row-controls {
    grid-column: 2;
    grid-row: 1/4;
    flex-direction: column;
    align-items: stretch;
  }
  .user-row-controls button {
    grid-row: auto;
  }
  .photo-control {
    min-height: 44px;
  }
  .agency-settings-form {
    padding: 20px;
  }
  .agency-settings-form input {
    height: 44px;
    font-size: 16px;
  }
  .table-footer {
    align-items: flex-start;
  }
  .form-save-row .small-button {
    min-height: 44px;
  }
  .record-overview .tenancy-form-grid {
    grid-template-columns: 1fr;
  }
  .signup-table th:first-child,
  .signup-table td:first-child {
    min-width: 150px;
    max-width: 150px;
  }
}

.agencies-table th { padding: 13px 16px; }
.agencies-table th, .agencies-table th:first-child { min-width: 0; }
.agencies-table td { white-space: normal; overflow-wrap: anywhere; }
.agencies-table td:first-child { width: 70%; }
