:root {
  --wine: #8a001b;
  --wine-dark: #650014;
  --wine-soft: #f8eef1;
  --ink: #27272e;
  --muted: #60606a;
  --line: #e5e5ea;
  --paper: #f5f5f7;
  --radius: 14px;
  font-family: Jost, 'Segoe UI', Arial, sans-serif;
  color: var(--ink);
  font-size: 15px;
  line-height: 1.5;
  font-synthesis: none;
  color-scheme: light;
}
[data-assignment] {
  margin-bottom: 24px;
}
.assignment-inline {
  padding: 0 4px;
}
.assignment-inline .followup-heading {
  flex-wrap: wrap;
  gap: 8px 16px;
}
.assignment-inline [data-assignee] {
  margin: 0;
}
.assignment-inline form {
  margin-top: 16px;
}
.assignment-inline [data-request] {
  min-height: 44px;
}
.split-work.single-column {
  grid-template-columns: minmax(0, 1fr);
}
.followup-panel {
  margin-bottom: 24px;
}
.followup-heading,
.followup-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.followup-heading {
  justify-content: space-between;
}
.followup-heading h2 {
  margin: 0;
}
.followup-heading [data-followup-state] {
  color: var(--wine);
  font-weight: 600;
}
.followup-fields {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  gap: 16px;
}
.followup-panel input {
  min-width: 0;
  max-width: 100%;
}
.followup-actions {
  margin-top: 16px;
}
.followup-recovery {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
}
.followup-recovery p {
  flex-basis: 100%;
  overflow-wrap: anywhere;
}
[data-followup-status] {
  margin-top: 12px;
}
[data-followup-status][role='alert'] {
  color: var(--wine-dark);
}
@media (max-width: 600px) {
  .followup-fields {
    grid-template-columns: minmax(0, 1fr);
    gap: 4px;
  }
  .followup-actions .btn {
    flex: 1 1 140px;
  }
  .followup-recovery .btn {
    width: 100%;
  }
}
* {
  box-sizing: border-box;
}
[hidden] {
  display: none !important;
}
html {
  scrollbar-gutter: stable;
}
body {
  margin: 0;
  background: var(--paper);
}
button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}
button,
a,
input,
select,
textarea {
  -webkit-tap-highlight-color: transparent;
}
button {
  cursor: pointer;
  border: 0;
  transition:
    background 0.16s,
    color 0.16s;
}
a {
  color: inherit;
  text-decoration: none;
}
h1,
h2,
h3,
p {
  margin: 0;
}
h1 {
  font-size: 32px;
  line-height: 1.22;
  font-weight: 650;
  letter-spacing: -0.035em;
}
h2 {
  font-size: 19px;
  letter-spacing: -0.02em;
}
h3 {
  font-size: 16px;
}
p {
  overflow-wrap: anywhere;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid #747480;
  outline-offset: 2px;
}
h1:focus,
h2:focus,
main:focus {
  outline: none;
}
::selection {
  background: #efd6de;
  color: #650014;
}
input,
textarea {
  caret-color: var(--wine);
}
button:disabled,
input:disabled,
select:disabled,
textarea:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}
svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  stroke-width: 1.65;
}
img {
  display: block;
  max-width: 100%;
}
.skip {
  position: fixed;
  top: -80px;
  left: 20px;
  z-index: 100;
  background: white;
  padding: 12px;
}
.skip:focus {
  top: 8px;
}
.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 238px;
  background: white;
  border-right: 1px solid var(--line);
  padding: 32px 18px 18px;
  display: flex;
  flex-direction: column;
  z-index: 20;
}
.brand {
  padding: 0 20px 30px;
}
.brand img {
  width: 125px;
  height: 75px;
  object-fit: contain;
  margin-bottom: 14px;
}
.brand span {
  font-size: 12px;
  color: var(--muted);
}
#nav {
  display: grid;
  gap: 5px;
}
.nav-link {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 13px 16px;
  min-height: 48px;
  border-radius: 8px;
  font-size: 14px;
  background: transparent;
  text-align: left;
}
.nav-link:hover {
  background: var(--paper);
}
.nav-link.active {
  background: var(--wine-soft);
  color: var(--wine);
}
.sidebar-bottom {
  margin-top: auto;
  padding: 20px 12px 0;
  border-top: 1px solid var(--line);
  font-size: 12px;
}
.workspace {
  margin-left: 238px;
}
.topbar {
  height: 76px;
  padding: 0 40px;
  background: white;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.breadcrumb {
  font-size: 13px;
  color: var(--muted);
}
.breadcrumb > span {
  padding: 0 16px;
}
.breadcrumb strong {
  color: var(--ink);
  font-weight: 550;
}
.mobile-brand,
.mobile-more {
  display: none;
}
.badge {
  font-size: 12px;
  display: inline-block;
  padding: 5px 9px;
  border-radius: 5px;
  background: var(--paper);
  color: var(--muted);
}
main {
  padding: 40px;
  min-height: calc(100dvh - 142px);
}
.page-heading {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: center;
  margin-bottom: 28px;
}
.page-heading p {
  margin-top: 7px;
  color: var(--muted);
  font-size: 14px;
  max-width: 65ch;
}
.heading-actions {
  display: flex;
  gap: 12px;
}
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 18px;
  min-height: 44px;
  border-radius: 6px;
  background: var(--wine);
  color: white;
  font-size: 13px;
  font-weight: 600;
  white-space: normal;
}
.btn:hover {
  background: var(--wine-dark);
}
.secondary {
  background: white;
  border: 1px solid var(--line);
  color: var(--ink);
}
.secondary:hover {
  background: var(--paper);
}
.text-btn,
.quiet {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 8px 6px;
  font-size: 13px;
  color: var(--wine);
  background: transparent;
}
.quiet {
  color: var(--muted);
}
.text-btn:hover,
.quiet:hover {
  text-decoration: underline;
  text-underline-offset: 4px;
}
.panel {
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  min-width: 0;
  overflow: clip;
}
.panel-head {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: center;
  padding: 23px;
  border-bottom: 1px solid var(--line);
}
.panel-head p {
  color: var(--muted);
  font-size: 13px;
  margin-top: 4px;
}
.summary-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 10px 0;
  margin-bottom: 28px;
}
.summary-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 24px;
  border-right: 1px solid var(--line);
  font-size: 13px;
}
.summary-item:last-child {
  border: 0;
}
.summary-item strong {
  font-size: 24px;
  font-variant-numeric: tabular-nums;
}
.summary-item svg {
  color: var(--wine);
}
.today-grid,
.split-work,
.team-layout {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 24px;
  align-items: start;
}
.column {
  display: grid;
  gap: 24px;
  min-width: 0;
}
.queue-row,
.team-row {
  padding: 20px 23px;
  border-bottom: 1px solid var(--line);
  display: flex;
  gap: 14px;
  align-items: center;
}
.queue-row:last-child,
.team-row:last-child {
  border: 0;
}
.queue-body,
.member-details {
  flex: 1;
  min-width: 0;
}
.queue-body p,
.member-details p,
.listing-mini p {
  font-size: 13px;
  color: var(--muted);
  margin: 4px 0;
}
.queue-body time {
  font-size: 12px;
  color: var(--muted);
  margin-left: 10px;
}
.queue-body h3 .text-btn {
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
  padding: 0;
  min-height: 28px;
}
.avatar {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  border-radius: 50%;
  background: var(--paper);
  color: var(--muted);
  display: grid;
  place-items: center;
  font-size: 12px;
}
.member-avatar {
  width: 56px;
  height: 56px;
  object-fit: cover;
  object-position: top;
  border-radius: 50%;
}
.member-details small {
  display: block;
  color: var(--muted);
  margin-top: 4px;
}
.team-row[data-selected='true'] {
  background: #fbf6f8;
}
.listing-mini {
  display: grid;
  grid-template-columns: 32px 1fr 20px;
  gap: 14px;
  padding: 20px 23px;
  border-bottom: 1px solid var(--line);
}
.listing-mini:hover {
  background: var(--paper);
}
.toolbar {
  display: flex;
  align-items: end;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}
.toolbar .field {
  margin: 0;
  flex: 1;
  min-width: 180px;
}
.property-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}
.property-content {
  padding: 24px;
}
.property-content h2 {
  margin: 16px 0 4px;
}
.property-price {
  font-size: 24px;
  margin: 16px 0;
  font-variant-numeric: tabular-nums;
}
.editor-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(280px, 1fr);
  gap: 24px;
  align-items: start;
}
.publication-panel {
  padding: 18px 0;
  margin-bottom: 24px;
  border-block: 1px solid var(--line);
  min-width: 0;
}
.publication-panel h2,
.team-detail .publication-panel h2 {
  font-size: 18px;
  margin-bottom: 6px;
}
.publication-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 14px 24px;
}
.publication-heading > div:first-child {
  flex: 1 1 260px;
  min-width: 0;
}
.publication-panel p {
  font-size: 13px;
  max-width: 70ch;
  overflow-wrap: anywhere;
}
.publication-panel .publication-help {
  color: var(--muted);
  margin-top: 8px;
}
.publication-panel [data-publication-status]:not(:empty),
.publication-panel [data-publication-details]:not(:empty),
.publication-panel .publication-actions:not(:empty) {
  margin-top: 14px;
}
.publication-panel .publication-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.publication-panel .btn {
  min-height: 44px;
  white-space: normal;
}
.publication-panel .field {
  max-width: 36rem;
  margin: 14px 0 0;
}
.team-detail .publication-panel {
  margin-top: 20px;
}
.editor-section {
  padding: 24px;
}
.editor-section > h2 {
  margin-bottom: 18px;
}
.editor-section > p {
  margin-bottom: 16px;
  max-width: 70ch;
}
.field-pair {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 18px;
}
.field {
  display: flex;
  flex-direction: column;
  gap: 7px;
  font-size: 13px;
  font-weight: 500;
  margin: 0 0 18px;
  min-width: 0;
}
.field input,
.field select,
.field textarea {
  width: 100%;
  min-width: 0;
  background: white;
  border: 1px solid #d6d6df;
  border-radius: 6px;
  min-height: 44px;
  padding: 10px 12px;
  resize: vertical;
  font-weight: 400;
}
.field textarea {
  min-height: 110px;
}
.field-help,
.muted {
  color: var(--muted);
  font-size: 12px;
}
.field-help {
  margin: 8px 0 16px;
  display: block;
}
.check-field {
  display: flex;
  gap: 12px;
  align-items: center;
  min-height: 44px;
  margin-bottom: 18px;
}
.check-field input {
  width: 20px;
  height: 20px;
  accent-color: var(--wine);
}
.room {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
  margin: 14px 0;
}
.room legend {
  font-weight: 600;
}
/* Grouped fields share the workspace palette and native controls. */
.property-facts {
  container-type: inline-size;
}
#property-form .field,
#property-form [data-feature-entry-controls] {
  scroll-margin-block: 16px;
}
.property-facts .fact-group {
  border-top: 1px solid var(--line);
  padding-top: 24px;
  margin-top: 12px;
}
.property-facts .fact-group > h3 {
  font-size: 15px;
  margin-bottom: 18px;
}
.property-facts summary {
  cursor: pointer;
  padding: 16px 0;
  min-height: 48px;
  font-weight: 600;
  overflow-wrap: anywhere;
}
.property-facts summary svg {
  width: 18px;
  height: 18px;
  vertical-align: middle;
  margin: 0 8px 2px 4px;
}
.property-facts summary small {
  display: block;
  margin: 6px 0 0 30px;
  font-weight: 400;
  color: var(--muted);
}
.property-facts summary:focus-visible {
  outline: 2px solid var(--wine);
  outline-offset: 3px;
}
.property-facts summary:hover,
.property-facts .number-step:not(:disabled):hover {
  background: var(--paper);
  color: var(--wine);
}
.property-facts .fact-group-fields {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0 18px;
  padding: 4px 0 16px;
}
.property-facts .fact-wide,
.property-facts .fact-measure,
.property-facts .fact-features,
.property-facts [data-fact-rooms] {
  grid-column: 1 / -1;
  min-width: 0;
}
.property-facts .fact-measure {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0 12px;
}
.property-facts .number-control {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 44px 44px;
  gap: 4px;
}
.property-facts .number-step {
  display: grid;
  place-items: center;
  min-width: 44px;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--wine);
  background: var(--paper);
}
.property-facts .number-step svg {
  width: 18px;
  height: 18px;
  transform: rotate(-90deg);
}
.property-facts .number-step[data-direction='-1'] svg {
  transform: rotate(90deg);
}
.property-facts .number-step:disabled {
  opacity: 0.45;
  cursor: default;
}
.property-facts .number-control input {
  font-variant-numeric: tabular-nums;
}
.property-facts .number-control input[type='number'] {
  appearance: textfield;
  -moz-appearance: textfield;
}
.property-facts .number-control input[type='number']::-webkit-inner-spin-button,
.property-facts
  .number-control
  input[type='number']::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
.property-facts .feature-option {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 8px;
  border-radius: 6px;
  overflow-wrap: anywhere;
}
.property-facts .feature-option:has(input:checked),
.property-facts .feature-option:focus-within {
  background: var(--paper);
}
.property-facts .feature-icon,
.property-facts .feature-icon svg {
  display: block;
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}
.property-facts .feature-icon {
  color: var(--muted);
}
.property-facts .feature-option > span:last-child {
  min-width: 0;
}
.property-facts .feature-option input {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  accent-color: var(--wine);
}
.property-facts [data-feature-options] {
  display: grid;
  gap: 4px;
  margin: 12px 0 18px;
}
.property-facts .room {
  border: 0;
  border-top: 1px solid var(--line);
  border-radius: 0;
  padding: 0 0 12px;
  margin: 0;
}
.property-facts .room .field-pair {
  grid-template-columns: minmax(0, 1fr);
}
.property-facts [data-fact-error] {
  color: var(--wine);
  font-size: 12px;
}
.property-facts [data-fact-error]:empty {
  display: none;
}
.property-facts .fact-validation {
  display: grid;
  gap: 8px;
}
.property-facts .fact-validation button {
  text-align: left;
  min-height: 44px;
}
@container (min-width: 520px) {
  .property-facts .fact-group-fields,
  .property-facts .room .field-pair {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .property-facts .fact-measure {
    grid-template-columns: minmax(0, 1fr) minmax(110px, 0.6fr);
  }
  .property-facts .room .fact-measure {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
.image-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}
.compact-gallery {
  container-type: inline-size;
  min-width: 0;
}
.compact-gallery .gallery-content {
  padding: 0 23px 23px;
}
.gallery-tools,
.gallery-issues,
.gallery-pager {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-block: 12px;
}
.compact-gallery .session-options {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.gallery-issues p {
  flex: 1 1 160px;
  font-size: 13px;
}
.gallery-thumbnails {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}
.gallery-thumbnail {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 44px;
  padding: 3px;
  border: 2px solid transparent;
  border-radius: 8px;
  background: var(--paper);
  color: var(--ink);
  text-align: left;
  cursor: pointer;
}
.gallery-thumbnail[aria-pressed='true'] {
  border-color: var(--wine);
}
.gallery-thumbnail:focus-visible {
  outline: 2px solid #747480;
  outline-offset: 2px;
}
.gallery-thumbnail img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 4px;
}
.gallery-thumb-number,
.gallery-thumb-status {
  display: block;
  padding: 3px 2px;
  font-size: 12px;
  line-height: 1.3;
  overflow-wrap: anywhere;
}
.gallery-thumb-number {
  font-weight: 600;
}
.gallery-pager {
  justify-content: space-between;
}
.gallery-pager > span {
  font-size: 12px;
  text-align: center;
  flex: 1 1 100px;
}
.gallery-selected {
  border-top: 1px solid var(--line);
  padding-top: 16px;
  margin-top: 16px;
  min-width: 0;
}
.gallery-selected:empty {
  display: none;
}
.gallery-selected h3 {
  font-size: 16px;
  margin-bottom: 12px;
}
.gallery-preview {
  display: block;
  width: 100%;
  height: 180px;
  object-fit: contain;
  background: var(--paper);
  border-radius: 8px;
}
.gallery-selected p {
  margin-block: 10px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.gallery-selected .field input {
  font-size: 16px;
}
.gallery-selected-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.compact-gallery .btn {
  min-height: 44px;
  white-space: normal;
}
.gallery-empty {
  grid-column: 1 / -1;
  padding-block: 24px;
}
@container (min-width: 600px) {
  .gallery-thumbnails {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }
}
.image-card {
  background: var(--paper);
  border-radius: 10px;
  overflow: hidden;
  min-width: 0;
}
.image-card > img {
  width: 100%;
  aspect-ratio: 1.25;
  object-fit: cover;
}
.image-card .field,
.image-card > p,
.image-card > .field-help,
.image-card > strong {
  margin: 8px;
  display: block;
  font-size: 12px;
}
.image-card .field input {
  padding: 8px;
  font-size: 13px;
}
.image-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 2px;
  padding: 6px;
}
.image-actions button {
  padding: 5px 2px;
  min-height: 44px;
  font-size: 11px;
  min-width: 0;
}
.image-actions .cover {
  grid-column: 1/-1;
  justify-content: center;
  border-top: 1px solid var(--line);
}
.photo-picker {
  position: relative;
  overflow: hidden;
}
.photo-picker input {
  position: absolute;
  inset: 0;
  opacity: 0;
  width: 100%;
  height: 100%;
  cursor: pointer;
}
.photo-picker:focus-within {
  outline: 2px solid #747480;
  outline-offset: 2px;
}
.photo-empty {
  grid-column: 1/-1;
  min-height: 130px;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 12px;
  color: var(--muted);
  border: 1px dashed #a8a8b2;
  border-radius: 8px;
}
.editor-actions {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  margin: 24px 0 4px;
}
.save-status,
[data-status]:not(:empty) {
  padding: 14px 0;
  font-size: 14px;
  overflow-wrap: anywhere;
}
.save-status:empty {
  display: none;
}
[role='alert'] {
  color: #8a001b;
}
.conflict {
  padding: 18px;
  border: 1px solid #d8bac0;
  border-radius: 8px;
  margin: 16px 0;
}
.conflict button {
  margin: 8px 8px 0 0;
}
.recovery-row {
  border-bottom: 1px solid var(--line);
  padding: 10px 0;
  font-size: 12px;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
}
.pagination {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 20px;
}
.empty {
  padding: 32px 24px;
  min-height: 150px;
}
.empty p {
  margin-top: 10px;
  color: var(--muted);
  font-size: 14px;
  max-width: 65ch;
}
.loading {
  min-height: 250px;
  padding: 32px;
  background: white;
  border-radius: 14px;
  color: var(--muted);
}
.team-back {
  display: none;
}
.team-detail > p {
  font-size: 13px;
  color: var(--muted);
}
.team-detail #portrait {
  margin-top: 24px;
  border-top: 1px solid var(--line);
}
.note {
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
.note p,
.message {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.note time {
  font-size: 12px;
  color: var(--muted);
}
dt {
  font-size: 12px;
  color: var(--muted);
  margin-top: 12px;
}
dd {
  margin: 4px 0;
  overflow-wrap: anywhere;
}
pre {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  max-height: 350px;
  overflow: auto;
  font: inherit;
  font-size: 13px;
  padding: 16px;
  background: var(--paper);
}
.marketing-tabs {
  display: flex;
  gap: 24px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 24px;
}
.marketing-tabs button {
  background: transparent;
  border-bottom: 2px solid transparent;
  min-height: 48px;
  padding: 10px 0;
  color: var(--muted);
  font-size: 14px;
}
.marketing-tabs button[aria-selected='true'] {
  border-color: var(--wine);
  color: var(--wine);
}
.workspace-footer {
  padding: 24px 40px;
  font-size: 12px;
  color: var(--muted);
}
.auth-panel {
  max-width: 490px;
  margin: 10vh auto;
  padding: 36px;
  background: white;
  border: 1px solid var(--line);
  border-radius: 14px;
  min-height: 0;
}
.auth-panel > img {
  margin-bottom: 24px;
}
.auth-panel h1 {
  font-size: 26px;
}
.auth-panel p {
  margin: 16px 0 24px;
}
.gate-actions {
  display: grid;
  gap: 12px;
}
.sign-in-form {
  display: grid;
  gap: 16px;
  text-align: left;
}
.sign-in-form .field {
  min-width: 0;
}
.sign-in-form [role='alert'] {
  margin: 0;
}
.sign-in-form [role='alert']:empty {
  display: none;
}
#toast:empty {
  display: none;
}
#toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--ink);
  color: white;
  padding: 14px 20px;
  border-radius: 8px;
  z-index: 40;
  max-width: calc(100% - 32px);
}
@media (max-width: 1200px) {
  .topbar {
    padding: 0 26px;
  }
  main {
    padding: 28px 26px;
  }
  .property-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .editor-layout {
    grid-template-columns: 1fr;
  }
  .team-layout {
    grid-template-columns: 1fr;
  }
  .team-layout.editing > .roster {
    display: none;
  }
  .team-layout:not(.editing) > .team-detail {
    display: none;
  }
  .team-back {
    display: inline-flex;
    margin-bottom: 16px;
  }
  .team-detail {
    max-width: 720px;
    width: 100%;
  }
  .today-grid,
  .split-work {
    grid-template-columns: 1fr;
  }
  .summary-item {
    padding: 12px 16px;
  }
  .team-detail .panel-head {
    padding-left: 0;
  }
  .team-detail #portrait > .editor-section {
    padding-left: 0;
    padding-right: 0;
  }
}
@media (max-width: 650px) {
  html {
    scrollbar-gutter: auto;
  }
  .sidebar {
    inset: auto 0 0;
    width: 100%;
    height: calc(70px + env(safe-area-inset-bottom));
    padding: 5px 8px env(safe-area-inset-bottom);
    border-right: 0;
    border-top: 1px solid var(--line);
  }
  .brand,
  .sidebar-bottom {
    display: none;
  }
  #nav {
    display: flex;
    justify-content: space-around;
    gap: 3px;
  }
  .nav-link {
    flex: 1;
    flex-direction: column;
    gap: 4px;
    padding: 8px 4px;
    min-width: 0;
    min-height: 56px;
    font-size: 10px;
  }
  .nav-link svg {
    width: 20px;
    height: 20px;
  }
  .nav-secondary {
    display: none;
  }
  .mobile-more {
    display: flex;
  }
  .workspace {
    margin-left: 0;
  }
  .topbar {
    height: 58px;
    padding: 0 16px;
  }
  .breadcrumb {
    display: none;
  }
  .mobile-brand {
    display: block;
  }
  .mobile-brand img {
    object-fit: contain;
  }
  .badge {
    font-size: 11px;
  }
  main {
    padding: 22px 16px 100px;
    min-height: calc(100dvh - 160px);
  }
  h1 {
    font-size: 25px;
  }
  .page-heading {
    display: block;
    margin-bottom: 22px;
  }
  .page-heading p {
    font-size: 13px;
  }
  .heading-actions {
    margin-top: 16px;
  }
  .heading-actions .btn {
    width: 100%;
  }
  .summary-strip {
    padding: 5px 0;
    margin-bottom: 20px;
  }
  .summary-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 9px 4px;
    text-align: center;
    font-size: 11px;
  }
  .summary-item strong {
    font-size: 22px;
  }
  .summary-item svg {
    height: 32px;
  }
  .today-grid,
  .split-work,
  .column {
    gap: 20px;
  }
  .panel-head {
    padding: 16px;
  }
  .compact-gallery .gallery-content {
    padding: 0 16px 16px;
  }
  .panel-head h2 {
    font-size: 17px;
  }
  .panel-head .text-btn {
    font-size: 12px;
  }
  .queue-row,
  .team-row {
    padding: 16px;
    gap: 10px;
  }
  .queue-row > .text-btn {
    font-size: 12px;
  }
  .queue-body time {
    display: block;
    margin: 5px 0;
  }
  .listing-mini {
    padding: 16px;
    grid-template-columns: 24px 1fr 16px;
    gap: 10px;
  }
  .listing-mini h3 {
    font-size: 14px;
  }
  .property-grid {
    grid-template-columns: 1fr;
  }
  .editor-section {
    padding: 20px;
  }
  .field-pair {
    gap: 0 12px;
  }
  .field input,
  .field select,
  .field textarea {
    font-size: 16px;
  }
  .editor-actions {
    position: sticky;
    bottom: calc(70px + env(safe-area-inset-bottom));
    z-index: 10;
    background: white;
    border-top: 1px solid var(--line);
    padding: 12px;
    margin: 22px -16px -12px;
  }
  .editor-actions .btn {
    width: 100%;
  }
  .keyboard-open .editor-actions {
    position: static;
  }
  #property-form .field,
  #property-form [data-feature-entry-controls] {
    scroll-margin-bottom: calc(160px + env(safe-area-inset-bottom));
  }
  .keyboard-open #property-form .field,
  .keyboard-open #property-form [data-feature-entry-controls] {
    scroll-margin-bottom: calc(86px + env(safe-area-inset-bottom));
  }
  .image-grid {
    gap: 10px;
  }
  .image-actions button {
    font-size: 10px;
    min-height: 44px;
  }
  .image-card .field input {
    font-size: 16px;
  }
  .workspace-footer {
    padding: 10px 16px calc(90px + env(safe-area-inset-bottom));
  }
  .team-detail {
    padding: 0;
    background: transparent;
    border: 0;
    overflow: visible;
  }
  .team-detail h2 {
    font-size: 24px;
  }
  .team-detail #portrait {
    background: white;
    border: 1px solid var(--line);
    border-radius: 14px;
  }
  .team-detail #portrait > .editor-section {
    padding: 16px;
  }
  .team-row {
    flex-wrap: wrap;
  }
  .team-row > .btn {
    margin-left: 50px;
    min-height: 44px;
  }
  .member-details {
    flex-basis: calc(100% - 70px);
  }
  .marketing-tabs {
    gap: 12px;
  }
  .marketing-tabs button {
    font-size: 12px;
    flex: 1;
    text-align: left;
  }
  .auth-panel {
    margin: 30px 16px;
    padding: 26px;
  }
  .auth-panel h1 {
    font-size: 24px;
  }
  .toolbar .field {
    min-width: 140px;
  }
  #more-menu:not([hidden]) {
    display: grid;
    position: absolute;
    bottom: calc(100% + 8px);
    right: 12px;
    width: 210px;
    padding: 8px;
    background: white;
    border: 1px solid var(--line);
    border-radius: 12px;
    box-shadow: 0 10px 24px #27272e15;
  }
  #more-menu .nav-link {
    flex-direction: row;
    justify-content: flex-start;
    font-size: 14px;
    min-height: 48px;
  }
  #toast {
    bottom: calc(84px + env(safe-area-inset-bottom));
  }
  .save-status {
    scroll-margin-bottom: 160px;
  }
}
@media (max-width: 380px) {
  .field-pair {
    grid-template-columns: 1fr;
  }
  .image-grid {
    gap: 7px;
  }
  .image-actions button {
    font-size: 9px;
  }
  .editor-section {
    padding: 16px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
/* Profile portrait and focused editor retain the approved roster/form composition. */
#portrait .image-grid {
  grid-template-columns: 1fr;
}
#portrait .image-card {
  display: grid;
  grid-template-columns: 86px 1fr;
  gap: 12px;
  padding: 12px;
  background: white;
}
#portrait .image-card > img {
  width: 86px;
  height: 86px;
  border-radius: 50%;
  object-position: top;
}
#portrait .image-actions {
  grid-column: 1/-1;
  display: flex;
  justify-content: flex-end;
}
#portrait .image-actions button:nth-child(-n + 2) {
  display: none;
}
#portrait .image-card > .field-help {
  grid-column: 2;
}
#portrait .photo-empty {
  min-height: 86px;
}
#portrait .panel-head {
  padding: 16px 0;
  border-bottom: 0;
}
#portrait .panel-head h2 {
  font-size: 16px;
}
#portrait > .editor-section {
  padding: 0;
}
.team-detail #portrait {
  margin: 16px 0 24px;
}
@media (max-width: 1200px) {
  .team-editing > .page-heading {
    display: none;
  }
  .team-detail {
    border: 0;
    background: transparent;
    padding: 0;
    max-width: none;
  }
  .team-detail #portrait {
    border: 1px solid var(--line);
    background: white;
    padding: 16px;
    border-radius: 14px;
  }
  .team-detail #portrait > .editor-section {
    padding: 0;
  }
}
@media (max-width: 650px) {
  main[data-view='today'] .page-heading {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px;
  }
  main[data-view='today'] .heading-actions {
    margin-top: 0;
  }
  main[data-view='today'] .heading-actions .btn {
    font-size: 12px;
    padding: 10px 12px;
  }
  main[data-view='today'] .page-heading h1 {
    font-size: 23px;
  }
  #portrait .image-card {
    grid-template-columns: 70px 1fr;
  }
  #portrait .image-card > img {
    width: 70px;
    height: 70px;
  }
  .team-detail #portrait {
    padding: 16px;
  }
}
@media (max-width: 380px) {
  .image-actions {
    grid-template-columns: repeat(2, minmax(44px, 1fr));
  }
  .image-actions button {
    font-size: 11px;
  }
  .image-actions button:nth-child(3) {
    grid-column: 1/-1;
  }
}
.property-photo {
  position: relative;
  overflow: hidden;
  margin: -24px -24px 20px;
  aspect-ratio: 1.7;
  background: var(--paper);
  display: grid;
  place-items: center;
  color: var(--muted);
}
.property-photo img {
  /* Any photo shape fills the same frame, so cards line up. */
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.property-photo > svg {
  width: 32px;
  height: 32px;
}

/* One editor surface; tabs change presentation, never form ownership. */
.property-editor-heading {
  margin-bottom: 20px;
}
.property-editor-heading h1 {
  font-size: 28px;
}
.property-editor-heading .text-btn {
  padding-inline: 0;
}
.property-editor {
  background: white;
  border: 1px solid var(--line);
  border-radius: 12px;
  min-width: 0;
  --editor-inset: 28px;
}
.editor-tabs {
  display: flex;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scrollbar-width: thin;
  border-bottom: 1px solid var(--line);
  padding: 0 var(--editor-inset);
  gap: 24px;
}
.editor-tabs [role='tab'] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  gap: 8px;
  min-height: 62px;
  padding: 12px 2px;
  border: 0;
  border-bottom: 3px solid transparent;
  color: var(--muted);
  background: transparent;
  font-weight: 500;
  white-space: nowrap;
}
.editor-tabs [aria-selected='true'] {
  color: var(--wine);
  border-bottom-color: var(--wine);
}
.editor-tabs [role='tab']:hover {
  color: var(--wine);
}
.editor-tabs svg {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
}
.editor-tabs [role='tab']:focus-visible,
.editor-tab-panel:focus-visible {
  outline: 2px solid var(--wine);
  outline-offset: -4px;
}
.editor-tab-panel {
  padding: 26px var(--editor-inset) 12px;
  min-width: 0;
}
.property-editor [data-editor-panel][hidden] {
  display: none;
}
.editor-panel-heading {
  margin-bottom: 24px;
}
.editor-panel-heading h2 {
  font-size: 20px;
  margin: 0 0 6px;
}
.editor-panel-heading p {
  color: var(--muted);
  font-size: 14px;
  max-width: 70ch;
}
.editor-essentials,
.editor-assignment {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0 22px;
}
.editor-assignment {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-bottom: 22px;
}
.property-editor .fact-group-fields {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0 22px;
}
.property-editor .fact-measure {
  grid-template-columns: minmax(0, 1fr) minmax(100px, 0.65fr);
  grid-column: span 2;
}
.property-editor .room .fact-measure {
  grid-column: 1 / -1;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.property-editor .room .field-pair {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.property-editor [data-feature-options] {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.property-editor [data-feature-entry-controls] {
  display: flex;
  align-items: end;
  flex-wrap: wrap;
  gap: 12px;
}
.property-editor [data-feature-entry-controls] .field {
  flex: 1 1 240px;
  margin: 0;
}
.property-editor [data-feature-feedback] {
  width: 100%;
}
.property-editor #editor-panel-rooms .fact-group {
  padding: 0;
  margin: 0;
  border: 0;
}
.property-editor #editor-panel-rooms .fact-group > h3 {
  display: none;
}
.property-editor .room summary {
  display: list-item;
  padding: 18px 8px;
}
.property-editor .room[open] {
  padding-bottom: 20px;
}
.property-editor .editor-save {
  position: sticky;
  bottom: 0;
  z-index: 9;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-top: 1px solid var(--line);
  padding: 14px var(--editor-inset);
  background: white;
  border-radius: 0 0 12px 12px;
}
.property-editor .editor-save > div:first-child {
  min-width: 0;
  max-height: 64px;
  overflow-y: auto;
}
.property-editor .editor-actions {
  position: static;
  margin: 0;
  padding: 0;
  border: 0;
  flex-shrink: 0;
}
.property-editor .save-status {
  padding: 0;
}
.property-editor > form > .fact-validation:not(:empty) {
  padding: 12px var(--editor-inset);
  border-top: 1px solid var(--line);
}
.editor-review-list {
  padding-left: 20px;
  margin-bottom: 16px;
}
.editor-review-list li {
  padding-block: 6px;
}
.property-editor #editor-publication {
  padding: 24px var(--editor-inset) 0;
}
.property-editor .publication-panel {
  border-top: 0;
  margin: 0;
  padding-top: 0;
}
.property-editor .gallery-content,
.property-editor .compact-gallery .panel-head {
  padding-inline: 0;
}
.property-editor .gallery-content {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  column-gap: 16px;
  align-items: center;
}
.property-editor .gallery-content > * {
  grid-column: 1 / -1;
}
.property-editor .gallery-tools {
  margin: 0;
}
.property-editor .session-options {
  grid-column: 2;
  grid-row: 2;
  align-items: center;
  justify-content: end;
}
.property-editor .gallery-content > .field-help {
  grid-column: 1;
  grid-row: 2;
  margin-top: 0;
  margin-bottom: 4px;
}
.property-editor .compact-gallery .panel-head {
  padding-top: 0;
  padding-bottom: 16px;
}
.property-editor .session-options {
  padding-top: 12px;
}
.property-editor .gallery-thumbnails {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}
.property-editor .gallery-preview {
  max-height: 320px;
  object-fit: contain;
  background: var(--paper);
}
.gallery-page-arrow {
  min-width: 44px;
  min-height: 44px;
  display: grid;
  place-items: center;
}
.gallery-page-arrow svg {
  width: 20px;
  height: 20px;
}
.gallery-page-arrow[data-gallery-focus='previous'] svg {
  transform: rotate(180deg);
}
@media (max-width: 1100px) {
  .property-editor .fact-group-fields {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .property-editor [data-feature-options] {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .editor-tabs {
    gap: 20px;
  }
}
@media (max-width: 600px) {
  .property-editor-heading {
    gap: 6px;
    margin-bottom: 16px;
  }
  .property-editor-heading h1 {
    font-size: 24px;
  }
  .property-editor-heading .heading-actions {
    order: -1;
  }
  .property-editor-heading p {
    font-size: 13px;
    margin-top: 4px;
  }
  .property-editor .editor-tab-panel {
    padding-top: 20px;
  }
  .property-editor .editor-panel-heading {
    margin-bottom: 18px;
  }
  .property-editor {
    --editor-inset: 16px;
  }
  .editor-tabs {
    gap: 20px;
  }
  .editor-tabs [role='tab'] {
    min-height: 56px;
  }
  .editor-essentials,
  .editor-assignment,
  .property-editor .fact-group-fields,
  .property-editor .room .field-pair,
  .property-editor [data-feature-options] {
    grid-template-columns: minmax(0, 1fr);
  }
  .property-editor .fact-measure,
  .property-editor .room .fact-measure {
    grid-column: 1 / -1;
    grid-template-columns: minmax(0, 1fr);
  }
  .property-editor .gallery-thumbnails {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .property-editor .gallery-content {
    grid-template-columns: minmax(0, 1fr);
  }
  .property-editor .gallery-tools,
  .property-editor .session-options {
    grid-column: 1;
    grid-row: auto;
    justify-content: start;
  }
  .property-editor .gallery-content > .field-help {
    grid-row: auto;
  }
  .property-editor .editor-save {
    bottom: calc(70px + env(safe-area-inset-bottom));
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    padding-block: 12px;
  }
  .property-editor .editor-save > div:first-child:empty {
    display: none;
  }
  .property-editor .editor-actions .btn {
    width: 100%;
  }
  .keyboard-open .property-editor .editor-save {
    position: static;
  }
}

/* Enquiry detail: context first, with a compact management rail. */
.workspace:has(.enquiry-detail) .topbar {
  display: none;
}
main:has(.enquiry-detail) {
  padding: 24px 32px 32px;
}
.enquiry-detail {
  max-width: 1220px;
  margin-inline: auto;
}
.enquiry-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 44px;
  color: var(--muted);
  font-size: 13px;
}
.enquiry-back:hover {
  color: var(--wine);
}
.enquiry-detail svg {
  width: 18px;
  height: 18px;
  flex: none;
}
.enquiry-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin: 8px 0 24px;
}
.enquiry-title h1 {
  margin: 4px 0 0;
  font-size: 28px;
  line-height: 1.2;
  letter-spacing: -0.025em;
  overflow-wrap: anywhere;
}
.enquiry-eyebrow {
  font-size: 13px;
  color: var(--muted);
}
.enquiry-eyebrow::first-letter,
.enquiry-stage-badge::first-letter {
  text-transform: uppercase;
}
.enquiry-stage-badge {
  padding: 5px 12px;
  border-radius: 5px;
  background: var(--wine-soft);
  color: var(--wine);
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
}
.enquiry-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  grid-template-rows: auto auto 1fr;
  grid-template-areas: 'contact management' 'notes management' 'reply management';
  align-items: start;
  gap: 16px 24px;
}
.enquiry-surface,
.enquiry-management {
  min-width: 0;
  background: white;
  border: 1px solid var(--line);
  border-radius: 12px;
}
.enquiry-contact {
  grid-area: contact;
  padding: 24px;
}
.enquiry-section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 4px 12px;
  margin-bottom: 16px;
}
.enquiry-detail h2 {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
}
.enquiry-reference {
  color: var(--muted);
  font-size: 12px;
}
.enquiry-contact .message {
  margin: 0 0 24px;
  font-size: 17px;
  line-height: 1.65;
  max-width: 65ch;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.enquiry-property {
  margin-bottom: 16px;
  color: var(--muted);
}
.enquiry-contact-details {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  margin: 0;
}
.enquiry-contact-details dt {
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 4px;
}
.enquiry-contact-details dd {
  margin: 0;
  font-size: 14px;
  overflow-wrap: anywhere;
}
.enquiry-contact-action {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px 16px;
  margin-top: 20px;
}
.enquiry-contact-action .field-help {
  margin: 0;
  overflow-wrap: anywhere;
}
.enquiry-management {
  grid-area: management;
  padding: 0 20px;
}
.enquiry-management > * + * {
  border-top: 1px solid var(--line);
}
.enquiry-management > * {
  padding: 20px 0;
  margin: 0;
}
.enquiry-management .panel,
.enquiry-management .assignment-inline {
  background: transparent;
  border: 0;
  border-radius: 0;
  padding: 0;
  margin: 0;
  overflow: visible;
}
.enquiry-management h2 {
  margin-bottom: 8px;
}
.enquiry-management [data-assignee],
.enquiry-management [data-responsibility],
.enquiry-management [data-stage-reason],
.enquiry-stage [data-current-stage] {
  font-size: 12px;
  color: var(--muted);
  margin: 0 0 12px;
}
.enquiry-management [data-stage-reason]:empty,
.enquiry-management [data-confirm]:empty,
.enquiry-management [data-assignment-status]:empty,
.enquiry-management [data-followup-status]:empty,
.enquiry-management .followup-recovery:empty {
  display: none;
}
.enquiry-detail .field {
  margin-bottom: 12px;
  gap: 5px;
}
.enquiry-management .followup-fields {
  grid-template-columns: minmax(0, 1fr);
  gap: 0;
}
.enquiry-management .followup-heading {
  gap: 6px;
  align-items: baseline;
}
.enquiry-management .followup-heading [data-followup-state] {
  font-size: 12px;
}
.enquiry-management .followup-actions {
  margin-top: 8px;
  gap: 8px;
}
.enquiry-management .btn {
  padding-inline: 12px;
  flex: 0 1 auto;
}
.enquiry-management .field-help {
  margin: 0 0 12px;
  font-size: 11px;
}
.enquiry-management [data-confirm],
.enquiry-management [data-assignment-status] {
  font-size: 13px;
  margin-top: 12px;
}
.enquiry-management [data-confirm] .btn {
  margin: 8px 8px 0 0;
}
.enquiry-management details {
  margin-top: 12px;
  font-size: 12px;
  color: var(--muted);
}
.enquiry-management summary {
  min-height: 44px;
  padding-block: 12px;
  cursor: pointer;
}
.enquiry-management [data-history] p {
  margin: 0 0 12px;
  overflow-wrap: anywhere;
}
.enquiry-stage form {
  display: flex;
  align-items: flex-end;
  gap: 8px;
}
.enquiry-stage .field {
  flex: 1;
  margin: 0;
}
.enquiry-stage .field > span {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
}
.enquiry-notes {
  grid-area: notes;
  padding: 24px;
}
.enquiry-notes textarea {
  min-height: 72px;
}
.enquiry-notes #notes {
  margin-top: 20px;
}
.enquiry-notes .note {
  padding: 16px 0;
  border-top: 1px solid var(--line);
}
.enquiry-notes .note p {
  overflow-wrap: anywhere;
  white-space: pre-wrap;
  margin: 0 0 8px;
}
.enquiry-reply {
  grid-area: reply;
}
.enquiry-reply > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 64px;
  padding: 16px 24px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
}
.enquiry-reply > summary::after {
  content: '+';
  font-size: 20px;
  font-weight: 400;
  color: var(--wine);
}
.enquiry-reply[open] > summary::after {
  content: '−';
}
.enquiry-reply > summary .muted {
  margin-left: auto;
  font-weight: 400;
}
.enquiry-reply-body {
  padding: 0 24px 24px;
}
.enquiry-reply-body > p {
  margin-bottom: 16px;
  color: var(--muted);
  overflow-wrap: anywhere;
}
.enquiry-feedback:not(:empty) {
  position: sticky;
  bottom: 16px;
  margin-top: 16px;
  background: var(--wine-soft);
  color: var(--wine-dark);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 12px 16px;
}
@media (max-width: 1140px) {
  .enquiry-grid {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: none;
    grid-template-areas: 'contact' 'management' 'notes' 'reply';
  }
  .enquiry-management {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 24px;
  }
  .enquiry-management > [data-followup] {
    grid-column: 1 / -1;
  }
  .enquiry-management > [data-assignment] {
    border-top: 0;
  }
  .enquiry-management .followup-fields {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
  }
}
@media (max-width: 760px) {
  .workspace:has(.enquiry-detail) .topbar {
    display: flex;
    height: 52px;
  }
  main:has(.enquiry-detail) {
    padding: 12px 16px 104px;
  }
  .enquiry-title {
    align-items: flex-start;
    margin: 4px 0 20px;
    gap: 12px;
  }
  .enquiry-title h1 {
    font-size: 23px;
  }
  .enquiry-contact,
  .enquiry-notes {
    padding: 20px;
  }
  .enquiry-contact .message {
    font-size: 16px;
    margin-bottom: 20px;
  }
  .enquiry-contact-details {
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
  }
  .enquiry-management {
    display: block;
  }
  .enquiry-management > [data-assignment] {
    border-top: 1px solid var(--line);
  }
  .enquiry-detail .field input,
  .enquiry-detail .field select,
  .enquiry-detail .field textarea {
    font-size: 16px;
  }
  .enquiry-management .followup-fields {
    grid-template-columns: minmax(0, 1fr);
    gap: 0;
  }
  .enquiry-reply > summary {
    padding-inline: 20px;
    flex-wrap: wrap;
  }
  .enquiry-reply > summary .muted {
    margin-left: 0;
  }
  .enquiry-reply-body {
    padding: 0 20px 20px;
  }
  .enquiry-feedback:not(:empty) {
    bottom: 88px;
  }
}
.enquiry-management .enquiry-edit {
  margin: 0;
  color: var(--ink);
}
.enquiry-management .enquiry-edit > summary {
  color: var(--wine);
  font-size: 13px;
  font-weight: 600;
  width: fit-content;
}
.enquiry-management .enquiry-history {
  margin: 0;
}
.enquiry-management .enquiry-next-action {
  margin: 0 0 8px;
  font-size: 14px;
  overflow-wrap: anywhere;
}
.enquiry-management .enquiry-edit[open] > summary {
  margin-bottom: 8px;
}

/* Properties: photo cards with the price on the photo, agent and enquiries linked. */
[data-property-filters] .btn {
  min-height: 38px;
  padding: 7px 14px;
  border-radius: 18px;
  font-weight: 500;
}
[data-property-filters] .btn[aria-pressed='true'] {
  background: var(--wine);
  border-color: var(--wine);
  color: white;
}
.property-grid .property-content {
  position: relative;
  padding: 0;
  border: 0;
  box-shadow: var(--card-shadow);
  display: flex;
  flex-direction: column;
}
.property-media {
  position: relative;
  display: block;
}
.property-grid .property-photo {
  margin: 0;
  aspect-ratio: 1.6;
}
.photo-price {
  position: absolute;
  left: 12px;
  bottom: 12px;
  padding: 6px 12px;
  border-radius: 8px;
  background: #1c0e11b8;
  color: white;
  font-size: 18px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.property-body {
  display: grid;
  gap: 4px;
  padding: 16px 18px 14px;
  flex: 1;
}
.property-body > .badge {
  position: absolute;
  top: 12px;
  left: 12px;
  background: white;
  color: var(--ink);
  font-weight: 600;
}
.property-body > .badge.state-published {
  color: #1f6b43;
}
.property-body > .badge.state-archived {
  color: var(--muted);
}
.property-note {
  margin: 0;
  font-size: 12px;
  color: var(--muted);
}
.property-body h2 {
  margin: 0;
  font-size: 17px;
  font-weight: 600;
}
.property-body h2 a:hover {
  color: var(--wine);
}
.property-body > p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}
.property-links {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 4px 12px;
  margin-top: auto;
  padding-top: 10px;
  border-top: 1px solid #f0e8e8;
}
.agent-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  font-size: 14px;
}
a.agent-chip:hover span:last-child {
  color: var(--wine);
  text-decoration: underline;
  text-underline-offset: 4px;
}
.agent-chip.muted {
  color: var(--muted);
}
.avatar-mini {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--wine-soft);
  color: var(--wine);
  font-size: 11px;
  font-weight: 600;
}
.property-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0 14px;
}
.property-actions .text-btn {
  color: var(--wine);
  font-weight: 600;
}

/* Long lists: page controls on a computer, "more load as you scroll" on a phone. */
.column-pages {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  margin: 2px 4px 0;
  color: var(--muted);
  font-size: 13px;
}
.column-pages span {
  margin-right: auto;
}
.column-pages button {
  min-height: 36px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
  color: var(--ink);
  font-size: 13px;
}
.column-pages button:disabled {
  color: #b4b4bc;
}
.board-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.list-end {
  margin: 2px 0 0;
  color: var(--muted);
  font-size: 13px;
  text-align: center;
}
.pager {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 20px;
}
.pager-text {
  color: var(--muted);
  font-size: 14px;
}
.pager-buttons {
  display: flex;
  align-items: center;
  gap: 6px;
}
.pager-step,
.pager-number {
  min-width: 40px;
  height: 40px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
  color: var(--ink);
  font-size: 14px;
}
.pager-step:disabled {
  color: #b4b4bc;
}
.pager-number[aria-current='page'] {
  border-color: var(--wine);
  background: var(--wine);
  color: white;
  font-weight: 600;
}
.pager-gap {
  color: var(--muted);
}
.phone-only {
  display: none;
}
@media (max-width: 650px) {
  .pager.phone-scroll {
    display: none;
  }
  .phone-only:not(:empty) {
    display: block;
    margin-top: 14px;
  }
}

/* Enquiry detail (direction B): who and what first, the home it is about, then assignment and next step. */
.enquiry-title {
  justify-content: flex-start;
  gap: 14px;
}
.enquiry-title > div {
  flex: 1;
  min-width: 0;
}
.enquiry-avatar {
  display: grid;
  place-items: center;
  flex: 0 0 52px;
  height: 52px;
  border-radius: 50%;
  background: #f1f1f4;
  font-size: 20px;
  font-weight: 600;
}
.enquiry-title .enquiry-eyebrow {
  margin: 2px 0 0;
  font-size: 14px;
  overflow-wrap: anywhere;
}
.enquiry-stage-badge.stage-in_progress {
  background: #e8effb;
  color: #1f4f9a;
}
.enquiry-stage-badge.stage-closed,
.enquiry-stage-badge.stage-spam {
  background: #f1f1f4;
  color: #45454f;
}
.enquiry-grid {
  grid-template-rows: none;
  grid-template-areas: 'contact management' 'stage management' 'notes management' 'reply management';
  gap: 16px 20px;
}
.enquiry-surface {
  border: 0;
  border-radius: 16px;
  box-shadow: var(--card-shadow);
}
.enquiry-stage {
  grid-area: stage;
  padding: 20px 24px;
}
.enquiry-stage form {
  display: flex;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 10px;
  max-width: 480px;
}
.enquiry-stage form .field {
  flex: 1;
  min-width: 180px;
  margin: 0;
}
.enquiry-contact blockquote.message {
  max-width: none;
  margin: 0 0 16px;
  padding: 16px;
  border-radius: 12px;
  background: var(--paper);
  font-size: 16px;
  line-height: 1.55;
}
.enquiry-contact-action {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}
.enquiry-contact-action .field-help {
  flex-basis: 100%;
}
.enquiry-management {
  display: grid;
  gap: 16px;
  padding: 0;
  background: none;
  border: 0;
  border-radius: 0;
}
.enquiry-management > * {
  padding: 18px;
  border-radius: 16px;
  background: white;
  box-shadow: var(--card-shadow);
}
.enquiry-management > * + * {
  border-top: 0;
}
.enquiry-management > [data-followup] {
  background: #fff7e8;
}
.enquiry-management > [data-followup] .panel {
  background: none;
}
.enquiry-management > .enquiry-home {
  display: flex;
  flex-direction: column;
  padding: 0;
  overflow: hidden;
  color: var(--ink);
}
.enquiry-management > .enquiry-home[hidden] {
  display: none;
}
.enquiry-home-photo {
  position: relative;
  display: block;
  height: 150px;
  background: #e9e9ee;
}
.enquiry-home-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.enquiry-home-photo strong {
  position: absolute;
  left: 10px;
  bottom: 10px;
  padding: 4px 10px;
  border-radius: 8px;
  background: #1c0e11b8;
  color: white;
  font-size: 16px;
  font-weight: 600;
}
.enquiry-home-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 12px 16px;
  font-size: 13px;
}
.enquiry-home-text > span:first-child {
  color: var(--muted);
  font-size: 12px;
}
.enquiry-home-text strong {
  font-size: 15px;
  font-weight: 600;
}
.enquiry-home-open {
  font-weight: 500;
}
.enquiry-home:hover .enquiry-home-open {
  color: var(--wine);
}
@media (max-width: 1140px) {
  .enquiry-grid {
    grid-template-areas: 'contact' 'management' 'stage' 'notes' 'reply';
  }
  .enquiry-management {
    grid-template-columns: minmax(0, 1fr);
  }
}
@media (max-width: 760px) {
  .enquiry-management {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
  }
  .enquiry-management > [data-assignment] {
    border-top: 0;
  }
  .enquiry-avatar {
    flex-basis: 44px;
    height: 44px;
    font-size: 18px;
  }
  .enquiry-stage {
    padding: 20px;
  }
}

/* Property editor (direction B): address as title, pill tabs, white cards, agent and website at the side. */
.editor-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 44px;
  color: var(--wine);
  font-size: 14px;
  font-weight: 500;
}
.editor-back svg {
  width: 16px;
  height: 16px;
}
.property-editor-heading {
  display: flex;
  align-items: center;
  gap: 16px;
}
.property-editor-heading > div {
  flex: 1;
  min-width: 0;
}
.property-editor-heading h1 {
  font-size: 30px;
  font-weight: 600;
  overflow-wrap: anywhere;
}
.property-editor-heading .badge {
  font-weight: 600;
}
.property-editor-heading .badge.state-published {
  background: #e7f4ec;
  color: #1f6b43;
}
.property-editor {
  background: none;
  border: 0;
  border-radius: 0;
  --editor-inset: 18px;
}
.editor-tabs {
  gap: 6px;
  margin-bottom: 16px;
  padding: 6px;
  border: 0;
  border-radius: 12px;
  background: white;
  box-shadow: var(--card-shadow);
}
.editor-tabs [role='tab'] {
  min-height: 40px;
  padding: 9px 16px;
  border: 0;
  border-radius: 8px;
}
.editor-tabs [aria-selected='true'] {
  background: var(--wine);
  color: white;
  font-weight: 600;
}
.editor-tabs [aria-selected='true']:hover {
  color: white;
}
.editor-tabs svg {
  display: none;
}
.property-editor:has(.has-aside) .editor-tabs {
  margin-right: 360px;
}
.property-facts.has-aside {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  align-items: start;
  column-gap: 20px;
}
.property-facts.has-aside > * {
  grid-column: 1;
}
.property-facts.has-aside > .editor-aside {
  grid-column: 2;
  grid-row: 1 / span 20;
}
.editor-tab-panel,
#editor-publication:not([hidden]) {
  margin-bottom: 16px;
  padding: 18px;
  border-radius: 16px;
  background: white;
  box-shadow: var(--card-shadow);
}
.editor-aside {
  display: grid;
  gap: 16px;
}
.editor-card {
  display: grid;
  gap: 12px;
  padding: 18px;
  border-radius: 16px;
  background: white;
  box-shadow: var(--card-shadow);
}
.editor-card h2 {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
}
.editor-card p {
  margin: 0;
  color: #45454f;
  font-size: 14px;
}
.editor-card .editor-assignment {
  grid-template-columns: minmax(0, 1fr);
  margin: 0;
}
.editor-photo-preview:empty {
  display: none;
}
.editor-photo-preview {
  margin-bottom: 24px;
}
.editor-photo-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 12px;
}
.editor-photo-head h2 {
  margin: 0;
  font-size: 17px;
}
.editor-photo-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 10px;
  height: 220px;
}
.editor-photo-grid img {
  width: 100%;
  height: 100%;
  min-height: 0;
  border-radius: 12px;
  object-fit: cover;
}
.editor-photo-grid button {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--paper);
  font-weight: 600;
}
.editor-photo-empty {
  display: grid;
  justify-items: center;
  gap: 6px;
  padding: 28px;
  border: 2px dashed #dcdce2;
  border-radius: 12px;
  background: #fafafa;
  text-align: center;
}
.editor-photo-empty span {
  color: var(--muted);
  font-size: 13px;
}
@media (max-width: 1100px) {
  .property-editor:has(.has-aside) .editor-tabs {
    margin-right: 0;
  }
  .property-facts.has-aside {
    grid-template-columns: minmax(0, 1fr);
  }
  .property-facts.has-aside > .editor-aside {
    grid-column: 1;
    grid-row: auto;
    order: 1;
    margin-bottom: 16px;
  }
  .property-facts.has-aside > .fact-validation,
  .property-facts.has-aside > .editor-save {
    order: 2;
  }
}
@media (max-width: 650px) {
  .property-editor-heading {
    margin-bottom: 12px;
  }
  .property-editor-heading h1 {
    font-size: 22px;
  }
  .editor-tabs {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    overflow: visible;
  }
  .editor-tabs [role='tab'] {
    min-height: 36px;
    padding: 8px 6px;
    border-radius: 18px;
    background: #f1f1f4;
    font-size: 13px;
  }
  .editor-tab-panel {
    padding: 14px;
    border-radius: 14px;
  }
  .editor-photo-grid {
    grid-template-columns: 1fr;
    height: 170px;
  }
  .editor-photo-grid > :not(:first-child) {
    display: none;
  }
  .property-editor .editor-save {
    position: fixed;
    inset: auto 0 0;
    z-index: 25;
    padding: 12px 16px calc(14px + env(safe-area-inset-bottom));
    background: white;
    border-top: 1px solid var(--line);
  }
  [data-screen='task'] main:has(.property-editor) {
    padding-bottom: 120px;
  }
  .editor-tabs [role='tab'][aria-selected='true'] {
    background: var(--wine);
    color: white;
  }
  /* An agent's Add property keeps the bottom menu; the Save bar sits above it. */
  [data-screen='main'] .property-editor .editor-save {
    bottom: calc(70px + env(safe-area-inset-bottom));
    padding-bottom: 12px;
  }
  [data-screen='main'] main:has(.property-editor) {
    padding-bottom: 180px;
  }
}

/* Assign and follow-up (direction B): who handles it, a searchable list of eligible people, quick follow-up choices. */
.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
.assignee-now {
  display: flex;
  align-items: center;
  gap: 12px;
}
.assignee-now p {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
}
.assignee-initial {
  display: grid;
  place-items: center;
  flex: 0 0 40px;
  height: 40px;
  border-radius: 50%;
  background: #f1f1f4;
  color: var(--ink);
  font-weight: 600;
}
.assign-help {
  margin: 8px 0 0;
}
.assign-editor > summary {
  color: var(--wine);
  font-weight: 600;
}
.assign-search {
  display: flex;
  align-items: center;
  margin: 10px 0;
  padding: 0 12px;
  border: 1px solid #dcdce2;
  border-radius: 10px;
  background: white;
}
.assign-search input {
  flex: 1;
  min-width: 0;
  min-height: 44px;
  border: 0;
  outline: none;
  background: transparent;
  font-size: 16px;
}
.assignee-list {
  display: grid;
  gap: 8px;
  max-height: 300px;
  margin-bottom: 12px;
  overflow-y: auto;
  overscroll-behavior: contain;
}
.assignee-list [role='radio'] {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 56px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: white;
  color: var(--ink);
  text-align: left;
}
.assignee-list [aria-checked='true'] {
  border: 2px solid var(--wine);
  background: #fbf3f5;
}
.assignee-name {
  display: flex;
  flex: 1;
  flex-direction: column;
  min-width: 0;
  font-weight: 600;
}
.assignee-name small {
  color: var(--muted);
  font-size: 13px;
  font-weight: 400;
}
.assignee-dot {
  flex: 0 0 22px;
  height: 22px;
  border: 2px solid #c9c9d1;
  border-radius: 50%;
}
[aria-checked='true'] .assignee-dot {
  border-color: var(--wine);
  background: radial-gradient(var(--wine) 0 4px, transparent 5px);
}
.assign-editor .followup-actions button[data-to]::after {
  content: ' to ' attr(data-to);
}
.assign-editor .followup-actions button:first-child {
  border-color: var(--wine);
  background: var(--wine);
  color: white;
}
.followup-quick {
  display: grid;
  gap: 8px;
  margin-bottom: 14px;
}
.followup-quick > span {
  font-size: 13px;
  font-weight: 600;
}
.followup-quick > div {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.followup-quick button {
  min-height: 40px;
  padding: 8px 14px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: white;
  color: var(--ink);
  font-size: 14px;
}
.followup-quick [data-when] {
  border-radius: 10px;
  font-size: 13px;
}
.followup-quick button:hover:not(:disabled) {
  border-color: var(--wine);
  color: var(--wine);
}
.board-help {
  flex-basis: 100%;
  order: 2;
  margin: -8px 0 0;
  color: var(--muted);
  font-size: 14px;
}
@media (max-width: 650px) {
  .followup-quick [data-when] {
    flex: 1;
  }
  .board-help {
    margin: 6px 0 0;
    font-size: 13px;
  }
}

/* Shell (E2R-UX-008i, canvas page B): the left menu from 900px; below, a slim white header and the bottom menu. */
.workspace-footer,
.topbar .breadcrumb {
  display: none;
}
.nav-count {
  margin-left: auto;
  min-width: 22px;
  padding: 1px 7px;
  border-radius: 11px;
  background: var(--wine);
  color: white;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.5;
  text-align: center;
}
.nav-count[hidden] {
  display: none;
}
.me-photo {
  display: grid;
  place-items: center;
  flex: none;
  overflow: hidden;
  border: 1px solid #000;
  border-radius: 50%;
  background: #f1f1f4;
  color: var(--ink);
  font-weight: 600;
}
.me-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
}
#more-menu:not([hidden]) {
  display: grid;
  position: fixed;
  z-index: 40;
  width: 216px;
  padding: 8px;
  background: white;
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: 0 10px 24px #27272e15;
}
#more-menu .nav-link {
  flex-direction: row;
  justify-content: flex-start;
  min-height: 44px;
  padding: 0 12px;
  font-size: 14px;
  color: var(--ink);
}
@media (min-width: 900px) {
  .sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    width: 248px;
    height: auto;
    padding: 26px 16px 20px;
    display: flex;
    flex-direction: column;
    gap: 22px;
    background: white;
    border: 0;
    border-right: 1px solid var(--line);
  }
  .brand {
    display: block;
    padding: 0 8px;
  }
  .brand img {
    display: block;
    width: 128px;
    height: auto;
    margin: 0;
  }
  .side-add {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    border-radius: 10px;
    background: var(--wine);
    color: white;
    font-size: 14px;
    font-weight: 600;
  }
  .side-add:hover {
    background: var(--wine-dark);
    color: white;
  }
  #nav {
    display: flex;
    flex-direction: column;
    gap: 4px;
  }
  #nav .nav-link {
    gap: 12px;
    min-height: 44px;
    padding: 0 12px;
    border-radius: 10px;
    color: #45454f;
    font-size: 15px;
    white-space: nowrap;
  }
  #nav .nav-link:hover {
    background: var(--paper);
    color: var(--ink);
  }
  #nav .nav-link.active {
    background: var(--wine-soft);
    color: var(--wine);
    font-weight: 600;
  }
  .sidebar-bottom {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: auto;
    padding: 14px 8px 0;
    border-top: 1px solid var(--line);
  }
  .me {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
    min-width: 0;
    padding: 0;
    border: 0;
    background: none;
    color: inherit;
    text-align: left;
    cursor: pointer;
  }
  .me .me-photo {
    width: 40px;
    height: 40px;
  }
  .me-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
  }
  .me-text strong {
    overflow: hidden;
    font-size: 14px;
    font-weight: 600;
    white-space: nowrap;
    text-overflow: ellipsis;
  }
  .me-text span {
    margin: 0;
    color: var(--muted);
    font-size: 12px;
  }
  #logout {
    flex: none;
    padding: 4px 0;
    border: 0;
    background: none;
    color: var(--muted);
    font-size: 13px;
  }
  #logout:hover {
    color: var(--wine);
  }
  #more-menu:not([hidden]) {
    top: auto;
    right: auto;
    left: 16px;
    bottom: 84px;
  }
  .workspace {
    margin-left: 248px;
  }
  .topbar {
    display: none;
  }
  main {
    max-width: 1240px;
    min-height: 100dvh;
    margin: 0 auto;
    padding: 32px 40px 40px;
  }
}
@media (min-width: 900px) and (max-width: 1100px) {
  main {
    padding: 28px 24px 36px;
  }
}
@media (max-width: 899.98px) {
  html {
    scrollbar-width: none;
  }
  html::-webkit-scrollbar {
    display: none;
  }
  .sidebar {
    position: fixed;
    inset: auto 0 0;
    z-index: 30;
    width: 100%;
    height: auto;
    padding: 8px 6px calc(10px + env(safe-area-inset-bottom));
    display: block;
    background: white;
    border: 0;
    border-top: 1px solid var(--line);
  }
  .brand,
  .side-add,
  .sidebar-bottom {
    display: none;
  }
  #nav {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(0, 1fr);
    gap: 0;
  }
  #nav .nav-link {
    position: relative;
    flex-direction: column;
    justify-content: center;
    gap: 3px;
    min-width: 0;
    min-height: 48px;
    padding: 2px;
    border-radius: 0;
    background: none;
    color: #45454f;
    font-size: 11px;
    white-space: nowrap;
  }
  #nav .nav-link svg {
    width: 22px;
    height: 22px;
  }
  #nav .nav-link.active {
    background: none;
    color: var(--wine);
    font-weight: 600;
  }
  #nav .nav-count {
    position: absolute;
    top: 0;
    left: calc(50% + 6px);
    min-width: 18px;
    padding: 0 5px;
    font-size: 10px;
  }
  .workspace {
    margin-left: 0;
  }
  .topbar {
    position: sticky;
    top: 0;
    z-index: 25;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    height: auto;
    padding: 10px 16px;
    background: white;
    border-bottom: 1px solid var(--line);
  }
  .mobile-brand {
    display: block;
  }
  .mobile-brand img {
    display: block;
    width: 84px;
    height: auto;
    object-fit: contain;
  }
  .topbar-actions {
    display: flex;
    align-items: center;
    gap: 10px;
  }
  .top-add {
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: var(--wine);
    color: white;
    font-size: 22px;
    font-weight: 500;
    line-height: 1;
  }
  .top-add:hover {
    color: white;
    background: var(--wine-dark);
  }
  .top-me {
    width: 38px;
    height: 38px;
    padding: 0;
    cursor: pointer;
  }
  #more-menu:not([hidden]) {
    top: 64px;
    right: 12px;
    bottom: auto;
    left: auto;
  }
  main {
    min-height: calc(100dvh - 60px);
    padding: 18px 16px 96px;
  }
  main h1 {
    font-size: 24px;
  }
  #toast {
    bottom: calc(84px + env(safe-area-inset-bottom));
  }
  [data-screen='task'] .sidebar {
    display: none;
  }
  [data-screen='task'] main {
    padding-bottom: 32px;
  }
  [data-screen='task'] #toast {
    bottom: calc(16px + env(safe-area-inset-bottom));
  }
}

/* Today (canvas page B): three tiles, Answer first beside Follow-ups, listings as photo tiles. */
.today {
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.today-head p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}
.today-head h1 {
  margin: 0;
  font-size: 30px;
  font-weight: 600;
}
.today-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}
.today-stat {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: white;
  color: var(--ink);
}
.today-stat:hover {
  border-color: #d5d5dc;
  color: var(--ink);
}
.today-stat-n {
  display: grid;
  place-items: center;
  flex: none;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  font-size: 20px;
  font-weight: 700;
}
.tone-wine .today-stat-n {
  background: var(--wine-soft);
  color: var(--wine);
}
.tone-due .today-stat-n {
  background: #fff3df;
  color: #8a5a00;
}
.tone-live .today-stat-n {
  background: #e8f5ee;
  color: #1f6b43;
}
.today-stat-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.today-stat-text strong {
  font-size: 15px;
  font-weight: 600;
  white-space: nowrap;
}
.today-stat-text > span {
  overflow: hidden;
  color: var(--muted);
  font-size: 13px;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.today-panels {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 20px;
}
.today-panel {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: white;
}
.answer-panel {
  flex: 2 1 460px;
}
.due-panel {
  flex: 1 1 260px;
}
.today-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 20px;
  border-bottom: 1px solid #ececf0;
  white-space: nowrap;
}
.today-panel-head h2 {
  margin: 0;
  font-size: 17px;
  font-weight: 600;
}
.today-panel-head h2 span,
.today-panel-head > span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 500;
}
.today-panel-head a,
.today-section-head a {
  color: var(--wine);
  font-size: 14px;
  font-weight: 500;
}
.today-panel-note {
  margin: 0;
  padding: 12px 20px;
  color: var(--muted);
  font-size: 13px;
}
.answer-row {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  padding: 14px 20px;
  border-bottom: 1px solid #f1f1f4;
}
.answer-photo,
.board-photo {
  position: relative;
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: 10px;
  background: #f1f1f4;
  color: #45454f;
  font-weight: 600;
}
.answer-photo {
  width: 44px;
  height: 44px;
}
.answer-photo img,
.board-photo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.answer-text {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
  color: var(--ink);
}
.answer-line {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  white-space: nowrap;
}
.answer-line strong {
  min-width: 0;
  overflow: hidden;
  font-size: 15px;
  font-weight: 600;
  text-overflow: ellipsis;
}
.answer-text:hover strong {
  color: var(--wine);
}
.answer-tag {
  flex: none;
  padding: 2px 8px;
  border-radius: 6px;
  background: #f1f1f4;
  color: #45454f;
  font-size: 12px;
  font-weight: 600;
}
.answer-when {
  flex: none;
  color: var(--muted);
  font-size: 12px;
}
.answer-preview {
  overflow: hidden;
  color: var(--muted);
  font-size: 14px;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.answer-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
.answer-agent,
.due-agent,
.board-face {
  display: grid;
  place-items: center;
  flex: none;
  overflow: hidden;
  border-radius: 50%;
  background: var(--wine-soft);
  color: var(--wine);
  font-weight: 600;
}
.answer-agent {
  width: 28px;
  height: 28px;
  font-size: 12px;
}
.answer-agent img,
.due-agent img,
.board-face img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
}
.answer-secondary,
.answer-reply {
  padding: 8px 12px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
}
.answer-secondary {
  border: 1px solid var(--line);
  color: var(--ink);
}
.answer-secondary:hover {
  border-color: var(--ink);
  color: var(--ink);
}
.answer-reply {
  background: var(--wine);
  color: white;
}
.answer-reply:hover {
  background: var(--wine-dark);
  color: white;
}
.due-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 20px;
  border-bottom: 1px solid #f1f1f4;
  color: var(--ink);
}
.due-row:hover strong {
  color: var(--wine);
}
.due-time {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: none;
  min-width: 52px;
  padding: 6px 0;
  border-radius: 10px;
  background: #fff3df;
  color: #8a5a00;
  line-height: 1.25;
}
.due-time strong {
  font-size: 14px;
  white-space: nowrap;
}
.due-time span {
  font-size: 11px;
}
.due-time span:empty {
  display: none;
}
.due-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
  min-width: 0;
}
.due-text strong,
.due-text span {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.due-text strong {
  font-size: 14px;
  font-weight: 600;
}
.due-text span {
  color: var(--muted);
  font-size: 13px;
}
.due-agent {
  width: 26px;
  height: 26px;
  font-size: 11px;
}
.today-section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
  white-space: nowrap;
}
.today-section-head h2 {
  margin: 0;
  font-size: 17px;
  font-weight: 600;
}
.listing-strip {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
}
.listing-strip > .empty {
  grid-column: 1 / -1;
}
.listing-tile {
  position: relative;
  display: block;
  height: 180px;
  overflow: hidden;
  border-radius: 14px;
  background: #3a3a42;
  color: white;
}
.listing-tile:hover {
  color: white;
}
.listing-tile img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.listing-tile-text {
  position: absolute;
  inset: auto 0 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 14px 16px;
  background: linear-gradient(transparent, #140e10c7);
}
.listing-tile-text strong {
  font-size: 17px;
  font-weight: 600;
}
.listing-tile-text span {
  overflow: hidden;
  font-size: 14px;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.listing-tile .badge {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 4px 9px;
  border-radius: 6px;
  background: white;
  color: var(--ink);
  font-size: 12px;
  font-weight: 600;
}
.listing-tile .badge.state-published {
  color: #1f6b43;
}
@media (max-width: 899.98px) {
  .today-head h1 {
    font-size: 24px;
  }
}
@media (max-width: 520px) {
  .answer-secondary {
    display: none;
  }
  .answer-row {
    gap: 12px;
    padding: 12px 16px;
  }
  .today-panel-head,
  .due-row {
    padding-left: 16px;
    padding-right: 16px;
  }
  .today-panel-note {
    padding: 12px 16px;
  }
}

/* Enquiries board (canvas page B): white columns that flow, compact rows; one list on a phone. */
.board-head {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px 16px;
  margin-bottom: 22px;
}
.board-head h1 {
  margin: 0;
  font-size: 30px;
  font-weight: 600;
  white-space: nowrap;
}
.board-agent {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 14px;
  white-space: nowrap;
}
.board-agent[hidden] {
  display: none;
}
.board-agent select,
.board-head input {
  width: auto;
  min-height: 40px;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
  color: var(--ink);
  font-size: 14px;
}
.board-head input {
  flex: 0 1 260px;
  min-width: 0;
  margin-left: auto;
  padding: 9px 14px;
}
.board-filters {
  display: none;
}
.board {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  align-items: start;
  gap: 18px;
}
.board-column,
.board-list {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: white;
}
.board-column h2 {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 14px 16px;
  border-bottom: 1px solid #ececf0;
  font-size: 15px;
  font-weight: 600;
  white-space: nowrap;
}
.board-column h2 > span:last-child {
  margin-left: auto;
  color: var(--muted);
  font-size: 13px;
  font-weight: 500;
}
.board-dot {
  flex: none;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--ink);
}
[data-column='in_progress'] .board-dot {
  background: #1f4f9a;
}
[data-column='closed'] .board-dot {
  background: var(--muted);
}
.board-empty,
.column-note {
  margin: 0;
  padding: 10px 16px;
  color: var(--muted);
  font-size: 12px;
}
.board-none {
  grid-column: 1 / -1;
}
.board-column .column-pages {
  padding: 10px 16px;
}
.board-card {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid #f1f1f4;
  color: var(--ink);
}
.board-card:hover {
  color: var(--ink);
  background: #fcfbfb;
}
.board-card:hover strong {
  color: var(--wine);
}
.board-photo {
  width: 40px;
  height: 40px;
}
.board-text {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}
.board-line {
  display: flex;
  align-items: baseline;
  gap: 8px;
  min-width: 0;
}
.board-line strong {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  font-size: 15px;
  font-weight: 600;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.board-line span {
  flex: none;
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
}
.board-topic {
  overflow: hidden;
  color: #45454f;
  font-size: 13px;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.board-meta {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  font-size: 12px;
}
.board-stage {
  display: none;
  flex: none;
  padding: 1px 7px;
  border-radius: 6px;
  font-weight: 600;
  white-space: nowrap;
}
.board-stage.stage-new {
  background: var(--wine-soft);
  color: var(--wine);
}
.board-stage.stage-in_progress {
  background: #e8effb;
  color: #1f4f9a;
}
.board-stage.stage-closed {
  background: #f1f1f4;
  color: #45454f;
}
.board-face {
  width: 20px;
  height: 20px;
  font-size: 10px;
}
.board-agent-chip {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  color: #45454f;
  font-weight: 500;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.board-agent-chip.unassigned {
  color: var(--wine);
  font-weight: 600;
}
.board-next {
  flex: none;
  color: var(--muted);
  font-weight: 600;
  white-space: nowrap;
}
.board-next.wine {
  color: var(--wine);
}
.board-next.due {
  color: #8a5a00;
}
@media (max-width: 650px) {
  .board-head {
    margin-bottom: 14px;
  }
  .board-head h1 {
    font-size: 24px;
  }
  .board-agent,
  .board-head input {
    display: none;
  }
  .board-filters {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 6px;
    margin-bottom: 14px;
  }
  .board-filters button {
    min-height: 40px;
    padding: 8px 2px;
    border: 1px solid var(--line);
    border-radius: 20px;
    background: white;
    color: #45454f;
    font-size: 13px;
    font-weight: 500;
    white-space: nowrap;
  }
  .board-filters button[aria-pressed='true'] {
    border-color: var(--wine);
    background: var(--wine);
    color: white;
    font-weight: 600;
  }
  .board {
    display: block;
  }
  .board-list .board-stage {
    display: inline;
  }
}

/* Team (canvas page B): cards that flow, one stats row, price-only listing photos. */
.team-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
}
@media (max-width: 380px) {
  .team-cards {
    grid-template-columns: minmax(0, 1fr);
  }
}
.team-card {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: white;
  box-shadow: none;
}
.team-card-head {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}
.team-card .avatar,
.team-card .member-avatar {
  display: grid;
  place-items: center;
  flex: 0 0 52px;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--wine-soft);
  color: var(--wine);
  font-size: 17px;
  font-weight: 600;
  object-fit: cover;
  object-position: top;
}
.team-card .member-details {
  display: flex;
  flex-direction: column;
  gap: 1px;
  flex: 1;
  min-width: 0;
}
.team-card h3,
.team-card .member-details p {
  margin: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.team-card h3 {
  font-size: 16px;
  font-weight: 600;
}
.team-card .member-details p {
  color: var(--muted);
  font-size: 13px;
}
.team-edit {
  flex: none;
  padding: 6px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 600;
}
.team-edit:hover {
  border-color: var(--ink);
  color: var(--ink);
}
.team-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border: 1px solid #ececf0;
  border-radius: 10px;
}
.team-stats[hidden] {
  display: none;
}
.team-stats a {
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 10px 12px;
  color: var(--ink);
}
.team-stats a + a {
  border-left: 1px solid #ececf0;
}
.team-stats a:hover {
  background: var(--paper);
  color: var(--ink);
}
.team-stats strong {
  font-size: 18px;
  line-height: 1.3;
}
.team-stats strong.is-due {
  color: #8a5a00;
}
.team-stats span {
  overflow: hidden;
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.team-empty {
  margin: 0;
  padding: 12px 14px;
  border-radius: 10px;
  background: var(--paper);
  color: var(--muted);
  font-size: 13px;
}
.team-listings {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}
.team-listings:empty {
  display: none;
}
.team-listings:has(.team-empty) {
  display: block;
}
.team-listing {
  position: relative;
  display: block;
  height: 72px;
  overflow: hidden;
  border-radius: 10px;
  background: #3a3a42;
  color: white;
}
.team-listing img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.team-listing-text {
  position: absolute;
  inset: auto 0 0;
  padding: 4px 6px;
  background: linear-gradient(transparent, #140e10cc);
  color: white;
}
.team-listing-text strong {
  display: block;
  overflow: hidden;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.page-heading p:empty {
  display: none;
}
@media (min-width: 900px) {
  /* The agent's Add property is the button above the menu. */
  #nav a[href='/workspace/properties/new'] {
    display: none;
  }
}

/* E2R-AUTH-005: the Team card's dashboard login line and the "Link a login" picker. */
.team-login {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid #ececf0;
}
.team-login[hidden] {
  display: none;
}
.team-login > svg {
  flex: 0 0 18px;
  width: 18px;
  height: 18px;
  color: #8a5a00;
}
.team-login > svg.is-linked {
  color: #1f6b43;
}
.team-login > span {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}
.team-login strong {
  font-size: 13px;
  font-weight: 600;
}
.team-login > span > span {
  overflow: hidden;
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.team-login .text-btn {
  flex: 0 0 auto;
  font-size: 13px;
}
.team-link-login {
  flex: 0 0 auto;
  min-height: 34px;
  padding: 0 10px;
  border: 1px solid var(--wine);
  border-radius: 8px;
  background: white;
  color: var(--wine);
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}
.login-dialog {
  width: min(480px, calc(100vw - 48px));
  max-height: calc(100dvh - 48px);
  padding: 22px;
  border: 0;
  border-radius: 16px;
  background: white;
  color: var(--ink);
  box-sizing: border-box;
}
.login-dialog::backdrop {
  background: rgb(20 14 16 / 45%);
}
.login-dialog h2 {
  margin: 0;
  font-size: 19px;
  font-weight: 600;
}
.login-dialog p {
  margin: 0 0 12px;
  color: #45454f;
  font-size: 14px;
  line-height: 1.45;
}
.login-dialog .login-dialog-sub {
  color: var(--muted);
  font-size: 13px;
}
.login-dialog .assignee-list {
  max-height: 260px;
}
.login-dialog .assignee-list [role='radio']:disabled {
  color: #9a9aa3;
}
.login-dialog .field-help {
  font-size: 12px;
}
.login-dialog-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}
.login-dialog-actions .login-remove {
  margin-right: auto;
}
@media (max-width: 899px) {
  .login-dialog {
    width: 100%;
    max-width: none;
    margin: auto 0 0;
    padding: 20px 16px 28px;
    border-radius: 16px 16px 0 0;
  }
}
