/* =====================================================================
   Bella portal — shared styles for login, project list and admin.
   The 3D viewer keeps its own styles inside index.html.

   Type: Archivo, one family used two ways — wide (title-block lettering
   on drawings) for headings, normal width for everything else.
   Gold is reserved for the primary action and the drafted linework.
   ===================================================================== */
:root {
  --b-page:      #16181c;
  --b-panel:     #1f2228;
  --b-panel-2:   #272b32;
  --b-line:      #353a42;
  --b-gold:      #c9a961;
  --b-gold-deep: #a88a45;
  --b-text:      #f2f1ee;
  --b-muted:     #9b9c98;
  --b-danger:    #e08a76;
  --b-ok:        #9fbf8f;
  --b-radius-sm: 6px;
  --b-radius:    12px;
  --b-font: 'Archivo', system-ui, -apple-system, 'Segoe UI', sans-serif;
}

[hidden] { display: none !important; }


.portal-page {
  margin: 0; min-height: 100vh; min-height: 100dvh;
  background: var(--b-page); color: var(--b-text);
  font-family: var(--b-font); font-size: 16px; line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
.portal-page *, .portal-page *::before, .portal-page *::after { box-sizing: border-box; }

.wide { font-stretch: 125%; font-variation-settings: 'wdth' 125; letter-spacing: 0.01em; }

/* Low-specificity default so .button / .portal-button colours still win. */
:where(.portal-page, .portal-screen) a { color: var(--b-gold); text-underline-offset: 3px; }
a.proj-name { color: var(--b-text); text-decoration: none; }
tr:hover a.proj-name, a.proj-name:focus-visible { text-decoration: underline; }

/* ---------- form controls ---------- */
.field { display: grid; gap: 6px; margin-bottom: 16px; }
.field label { font-size: 14px; color: var(--b-muted); }
.input, .select, .textarea {
  width: 100%; font: inherit; color: var(--b-text);
  background: var(--b-page); border: 1px solid var(--b-line); border-radius: var(--b-radius-sm);
  padding: 12px 14px; min-height: 48px;
  transition: border-color 0.15s ease;
}
.textarea { min-height: 88px; resize: vertical; }
.input:hover, .select:hover, .textarea:hover { border-color: #4a505a; }
.input:focus-visible, .select:focus-visible, .textarea:focus-visible { outline: none; border-color: var(--b-gold); box-shadow: 0 0 0 3px rgba(201,169,97,0.25); }

.portal-button, .button {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: inherit; font-weight: 600; cursor: pointer; text-decoration: none;
  min-height: 48px; padding: 0 22px; border-radius: var(--b-radius-sm); border: 1px solid transparent;
}
.portal-button { background: var(--b-gold); color: #1b1710; width: 100%; }
.portal-button:hover { background: #d6b874; }
.portal-button:disabled { opacity: 0.6; cursor: progress; }
.button { background: var(--b-panel-2); color: var(--b-text); border-color: var(--b-line); min-height: 40px; padding: 0 16px; font-size: 14px; }
.button:hover { border-color: #4a505a; }
.button.primary { background: var(--b-gold); color: #1b1710; border-color: var(--b-gold); }
.button.danger { color: var(--b-danger); }
.portal-link-button {
  background: none; border: none; padding: 8px 0; font: inherit; font-size: 15px;
  color: var(--b-muted); cursor: pointer; text-decoration: underline; text-underline-offset: 3px;
}
.portal-link-button:hover { color: var(--b-text); }
.portal-button:focus-visible, .button:focus-visible, .portal-link-button:focus-visible, .project-row:focus-visible, a:focus-visible {
  outline: 2px solid var(--b-gold); outline-offset: 3px;
}

.message { border-radius: var(--b-radius-sm); padding: 12px 14px; font-size: 15px; margin-bottom: 16px; }
.message.error { background: rgba(224,138,118,0.12); color: #f0b4a5; }
.message.ok    { background: rgba(159,191,143,0.12); color: #c3dcb7; }

/* ---------- status track (a real sequence: scanned → delivered) ---------- */
.status-track {
  list-style: none; margin: 0; padding: 0; display: flex; gap: 4px;
  font-size: 12px; color: var(--b-muted);
}
.status-track li { flex: 1; padding-top: 8px; border-top: 3px solid var(--b-line); white-space: nowrap; }
.status-track li.done { border-top-color: var(--b-gold-deep); }
.status-track li.current { border-top-color: var(--b-gold); color: var(--b-text); font-weight: 600; }

/* ---------- full-screen panels inside the viewer page ---------- */
.portal-screen {
  position: fixed; inset: 0; z-index: 200; overflow-y: auto;
  background: var(--b-page); color: var(--b-text); font-family: var(--b-font);
  padding: max(28px, env(safe-area-inset-top)) 20px 32px;
  display: flex; flex-direction: column; align-items: center; gap: 28px;
}
.portal-screen-logo { width: 132px; height: auto; }
.portal-screen-body { width: 100%; max-width: 560px; }
.portal-title { font-size: 26px; font-weight: 700; line-height: 1.2; margin: 0 0 12px; font-stretch: 125%; font-variation-settings: 'wdth' 125; }
.portal-text { color: var(--b-muted); margin: 0 0 20px; max-width: 46ch; }

.project-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.project-row {
  display: grid; gap: 4px; padding: 18px; border-radius: var(--b-radius);
  background: var(--b-panel); border: 1px solid var(--b-line);
  color: inherit; text-decoration: none;
}
.project-row { transition: box-shadow 0.14s ease, border-color 0.14s ease; }
@media (hover: hover) {
  .project-row:hover {
    border-color: var(--b-gold);
    box-shadow: 0 0 0 1.5px var(--b-gold), 0 0 10px color-mix(in srgb, var(--b-gold) 55%, transparent);
  }
}
.project-row-name { font-size: 18px; font-weight: 600; }
.project-row-address { color: var(--b-muted); font-size: 14px; margin-bottom: 10px; }

/* ---------- login ---------- */
.login {
  min-height: 100vh; min-height: 100dvh;
  display: grid; grid-template-rows: auto 1fr;
}
.login-drawing {
  position: relative; overflow: hidden;
  height: 38vh; min-height: 220px; max-height: 360px;
  background: radial-gradient(circle at 50% 115%, rgba(201,169,97,0.10), transparent 60%), var(--b-page);
  border-bottom: 1px solid var(--b-line);
}
.login-drawing svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.login-drawing .ink { fill: none; stroke: var(--b-gold); stroke-width: 1.6; stroke-linecap: square; stroke-linejoin: miter; }
.login-drawing .ink-light { fill: none; stroke: var(--b-gold); stroke-width: 0.8; opacity: 0.55; }
.login-drawing .dim-text { fill: var(--b-gold); font-family: var(--b-font); font-size: 12px; opacity: 0.8; }
/* Every drawn path has pathLength="1", so one dash value fits all of them. */
.login-drawing .draw { stroke-dasharray: 1; stroke-dashoffset: 1; animation: draw 2.2s cubic-bezier(0.45, 0, 0.2, 1) forwards; animation-delay: var(--delay, 0s); }
.login-drawing .fade { opacity: 0; animation: fade 0.8s ease forwards; animation-delay: var(--delay, 2s); }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes fade { to { opacity: 0.8; } }

.login-panel { width: 100%; max-width: 420px; margin: 0 auto; padding: 32px 22px 40px; }
.login-logo { width: 150px; height: auto; display: block; margin-bottom: 28px; }
/* The wordmark file is black; show it white on the dark pages. */
.login-logo, .portal-screen-logo, .admin-bar img { filter: invert(1); }
.login-title { font-size: 28px; font-weight: 700; line-height: 1.15; margin: 0 0 8px; font-stretch: 125%; font-variation-settings: 'wdth' 125; }
.login-lede { color: var(--b-muted); margin: 0 0 28px; }
.login-footer { margin-top: 28px; font-size: 13px; color: var(--b-muted); }
.login-actions { display: flex; justify-content: space-between; align-items: center; margin-top: 8px; }

@media (min-width: 900px) {
  .login { grid-template-rows: none; grid-template-columns: minmax(0, 1.25fr) minmax(420px, 1fr); }
  .login-drawing { height: auto; max-height: none; border-bottom: none; border-right: 1px solid var(--b-line); }
  .login-panel { align-self: center; padding: 48px; }
}

/* ---------- admin ---------- */
.admin { max-width: 1180px; margin: 0 auto; padding: 0 20px 64px; }
.admin-bar {
  position: sticky; top: 0; z-index: 60;
  display: flex; align-items: center; gap: 16px; flex-wrap: wrap;
  padding: 16px 0; background: var(--b-page); border-bottom: 1px solid var(--b-line); margin-bottom: 24px;
}
.admin-bar img { height: 22px; width: auto; }
.admin-bar .spacer { flex: 1; }
.admin-bar a { color: var(--b-muted); font-size: 14px; }
.admin-h1 { font-size: 24px; font-weight: 700; margin: 0; font-stretch: 125%; font-variation-settings: 'wdth' 125; }
.admin-h2 { font-size: 17px; font-weight: 700; margin: 0 0 14px; }
.admin-tools { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin-bottom: 16px; }
.admin-tools .input { max-width: 360px; min-height: 42px; padding: 8px 12px; }
.admin-tools .select { min-height: 42px; padding: 8px 12px; width: auto; }

/* Header: logo, a Quotes | Dashboard switch, and the user pill (Settings and Sign out inside). */
.admin-switch { display: inline-flex; padding: 3px; gap: 2px; border-radius: 999px; background: var(--b-panel); border: 1px solid var(--b-line); margin-left: 8px; }
.admin-bar .admin-switch a { padding: 7px 18px; border-radius: 999px; color: var(--b-muted); font-size: 14px; font-weight: 600; text-decoration: none; line-height: 1.2; }
.admin-bar .admin-switch a:hover { color: var(--b-text); }
.admin-bar .admin-switch a[aria-current="page"] { background: var(--b-gold); color: #1b1710; }
.admin-switch a:focus-visible, .user-pill:focus-visible, .user-menu-list a:focus-visible, .user-menu-list button:focus-visible { outline: 2px solid var(--b-gold); outline-offset: 2px; }
.user-menu { position: relative; }
.user-pill { display: inline-flex; align-items: center; gap: 8px; padding: 4px 12px 4px 4px; border-radius: 999px; cursor: pointer;
  background: var(--b-panel); border: 1px solid var(--b-line); color: var(--b-text); font: inherit; font-size: 14px; font-weight: 600; max-width: 220px; }
.user-pill:hover { border-color: var(--b-gold); }
.user-pill #whoAmI { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-pill::after { content: ''; width: 6px; height: 6px; border-right: 2px solid var(--b-muted); border-bottom: 2px solid var(--b-muted); transform: rotate(45deg) translate(-2px, -2px); flex: none; }
.user-avatar { width: 28px; height: 28px; border-radius: 50%; background: var(--b-gold); color: #1b1710; display: inline-flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700; flex: none; }
.user-menu-list { position: absolute; right: 0; top: calc(100% + 8px); min-width: 180px; padding: 6px; display: grid; gap: 2px; z-index: 20;
  background: var(--b-panel); border: 1px solid var(--b-line); border-radius: 14px; box-shadow: 0 12px 32px rgba(0,0,0,0.45); }
.user-menu-list a, .user-menu-list button { display: block; width: 100%; text-align: left; padding: 10px 12px; border: 0; border-radius: 10px; background: none; cursor: pointer;
  color: var(--b-text); font: inherit; font-size: 14px; text-decoration: none; }
.user-menu-list a:hover, .user-menu-list button:hover { background: var(--b-panel-2); }
@media (max-width: 700px), (max-height: 500px) {
  .admin-bar { gap: 10px; }
  .admin-switch { margin-left: 0; }
  .admin-bar .admin-switch a { padding: 7px 12px; }
  .user-pill #whoAmI { display: none; }
  .user-pill { padding-right: 8px; }
}

/* Show: MI_ only | All (Materials page) */
.filter-toggle { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 0 0 16px; }
.filter-toggle button { min-height: 38px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--b-line); background: none; color: var(--b-muted); font: inherit; font-size: 14px; cursor: pointer; }
.filter-toggle button[aria-pressed="true"] { color: var(--b-text); background: var(--b-panel-2); box-shadow: inset 0 0 0 1px var(--b-gold-deep); }
.filter-toggle .proj-sub { margin-left: 4px; }

.check-line { display: flex; align-items: center; gap: 8px; margin-top: 6px; font-size: 13px; color: var(--b-muted); cursor: pointer; }
.check-line input { width: 18px; height: 18px; accent-color: var(--b-gold); margin: 0; }
.contact-quick { display: flex; gap: 16px; flex-wrap: wrap; margin: -4px 0 16px; font-size: 15px; }

/* Project page tabs */
.admin-tabs { display: flex; gap: 2px; overflow-x: auto; border-bottom: 1px solid var(--b-line); margin: 0 0 24px; scrollbar-width: none; }
.admin-tabs::-webkit-scrollbar { display: none; }
.admin-tabs button {
  font: inherit; font-size: 15px; font-weight: 600; white-space: nowrap; cursor: pointer;
  background: none; border: 0; border-bottom: 3px solid transparent; margin-bottom: -1px;
  color: var(--b-muted); padding: 10px 14px;
}
.admin-tabs a {
  font: inherit; font-size: 15px; font-weight: 600; white-space: nowrap; text-decoration: none;
  border-bottom: 3px solid transparent; margin-bottom: -1px;
  color: var(--b-muted); padding: 10px 14px;
}
.admin-tabs a:hover { color: var(--b-text); }
.admin-tabs a[aria-current="page"] { color: var(--b-text); border-bottom-color: var(--b-gold); }
.admin-tabs button:hover { color: var(--b-text); }
.admin-tabs button[aria-selected="true"] { color: var(--b-text); border-bottom-color: var(--b-gold); }
.admin-tabs button:focus-visible { outline: 2px solid var(--b-gold); outline-offset: -2px; }
.tab-narrow { max-width: 900px; }

/* Quotes */
.q-actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.q-list { display: grid; }
.q-row { display: flex; gap: 6px; align-items: flex-start; padding: 8px 0; border-bottom: 1px solid var(--b-line); }
.q-row > :first-child { flex: 1; min-width: 0; }
.q-inline { display: flex; gap: 8px; flex-wrap: wrap; }
.q-inline .input { flex: 1 1 200px; min-height: 42px; padding: 8px 12px; }
.q-inline .q-money { flex: 0 1 130px; }
.q-stack { display: grid; gap: 8px; }
.q-row .textarea { width: 100%; }
.q-remove { background: none; border: 0; color: var(--b-muted); cursor: pointer; padding: 10px 8px; font-size: 15px; line-height: 1; }
.q-remove:hover { color: var(--b-danger); }
.q-send { background: var(--b-panel); border: 1px solid var(--b-line); border-radius: var(--b-radius); padding: 18px; margin: 16px 0 0; max-width: 720px; }
.q-preview { margin-top: 24px; }
.q-pdf { display: block; width: 100%; height: 80vh; margin-top: 12px; border: 1px solid var(--b-line); border-radius: var(--b-radius-sm); background: #fff; }
fieldset.q-readonly { border: 0; margin: 0; padding: 0; min-width: 0; }
fieldset.q-readonly .button, fieldset.q-readonly .q-remove, fieldset.q-readonly .portal-link-button { display: none; }

/* Materials tables */
.mat-table td { vertical-align: middle; padding: 10px 12px; }
.mat-name { font-family: ui-monospace, 'Cascadia Mono', Consolas, monospace; font-size: 13.5px; overflow-wrap: anywhere; }
.mat-final { font-weight: 700; font-variant-numeric: tabular-nums; }
.admin-toast {
  position: fixed; z-index: 100; left: 50%; bottom: max(20px, env(safe-area-inset-bottom)); transform: translateX(-50%);
  max-width: min(92vw, 480px); padding: 12px 16px; border-radius: var(--b-radius-sm);
  background: var(--b-panel-2); color: var(--b-text); border: 1px solid var(--b-line); border-left: 3px solid var(--b-ok);
  box-shadow: 0 8px 28px rgba(0,0,0,0.4); font-size: 14px;
}

.proj-table { width: 100%; border-collapse: collapse; }
.proj-table th { text-align: left; font-size: 13px; font-weight: 500; color: var(--b-muted); padding: 8px 12px; border-bottom: 1px solid var(--b-line); }
.proj-table td { padding: 14px 12px; border-bottom: 1px solid var(--b-line); vertical-align: top; }
.proj-table tr[data-href] { cursor: pointer; }
.proj-table tr[data-href] td { transition: box-shadow 0.14s ease; }
@media (hover: hover) {
  .proj-table tr[data-href]:hover td {
    background: transparent;
    box-shadow: inset 0 1.5px 0 var(--b-gold), inset 0 -1.5px 0 var(--b-gold);
  }
  .proj-table tr[data-href]:hover td:first-child { box-shadow: inset 1.5px 0 0 var(--b-gold), inset 0 1.5px 0 var(--b-gold), inset 0 -1.5px 0 var(--b-gold); }
  .proj-table tr[data-href]:hover td:last-child { box-shadow: inset -1.5px 0 0 var(--b-gold), inset 0 1.5px 0 var(--b-gold), inset 0 -1.5px 0 var(--b-gold); }
}
.proj-name { font-weight: 600; }
.proj-sub { color: var(--b-muted); font-size: 14px; }
.badge-new { display: inline-block; margin-left: 8px; padding: 1px 8px; border-radius: 999px; background: var(--b-gold); color: #1b1710; font-size: 12px; font-weight: 700; }
.empty { color: var(--b-muted); padding: 32px 0; }

.detail { display: grid; gap: 32px; }
@media (min-width: 980px) { .detail { grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); align-items: start; } }
.section { padding-bottom: 28px; border-bottom: 1px solid var(--b-line); margin-bottom: 28px; }
.section:last-child { border-bottom: none; }
.row-2 { display: grid; gap: 0 16px; align-items: start; }
input[type="file"].input { padding: 8px; min-height: 0; color: var(--b-muted); font-size: 14px; }
input[type="file"].input::file-selector-button {
  font: inherit; font-weight: 600; color: var(--b-text); background: var(--b-panel-2);
  border: 1px solid var(--b-line); border-radius: var(--b-radius-sm); padding: 8px 14px; margin-right: 12px; cursor: pointer;
}
input[type="file"].input::file-selector-button:hover { border-color: #4a505a; }
@media (min-width: 640px) { .row-2 { grid-template-columns: 1fr 1fr; } }
.hint { font-size: 13px; color: var(--b-muted); margin: -8px 0 16px; }
.imp-list { list-style: none; margin: 0; padding: 0; }
.imp-row { border-bottom: 1px solid var(--b-line); padding: 8px 0; }
.imp-row.off .imp-name, .imp-row.off .imp-ico { opacity: .5; }
.imp-main { display: flex; align-items: center; gap: 10px; }
.imp-tick { display: inline-flex; align-items: center; cursor: pointer; }
.imp-tick input { width: 18px; height: 18px; accent-color: var(--b-gold, #c9a961); cursor: pointer; }
.imp-ico { display: inline-flex; color: var(--b-gold, #c9a961); flex: none; }
.imp-name { flex: 1; min-width: 0; display: flex; flex-direction: column; font-size: 15px; }
.imp-title { overflow-wrap: anywhere; }
.imp-name .meta { color: var(--b-muted); font-size: 13px; }
.imp-actions { display: inline-flex; gap: 6px; flex: none; }
.imp-btn { display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; border-radius: 10px; border: 1px solid var(--b-line); background: transparent; color: var(--b-text, inherit); cursor: pointer; }
.imp-btn .imp-ico { color: inherit; }
@media (hover: hover) { .imp-btn:hover { border-color: var(--b-gold, #c9a961); box-shadow: 0 0 0 3px rgba(201,169,97,.18); } }
.imp-btn:focus-visible, .imp-tick input:focus-visible { outline: none; border-color: var(--b-gold, #c9a961); box-shadow: 0 0 0 3px rgba(201,169,97,.35); }
.file-list { list-style: none; margin: 0; padding: 0; }
.file-list li { display: flex; gap: 12px; align-items: baseline; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid var(--b-line); font-size: 15px; }
.file-list .meta { color: var(--b-muted); font-size: 13px; }
.history { color: var(--b-muted); font-size: 13px; }
.history summary { cursor: pointer; padding: 6px 0; }

.comment { padding: 14px 0; border-bottom: 1px solid var(--b-line); }







.tag { font-size: 12px; padding: 1px 8px; border-radius: 999px; border: 1px solid var(--b-line); color: var(--b-muted); }
.tag.bella { border-color: var(--b-gold-deep); color: var(--b-gold); }
.tag.ok { border-color: rgba(159,191,143,0.5); color: #c3dcb7; }
.tag.warn { border-color: rgba(224,138,118,0.5); color: #f0b4a5; }

.progress { height: 4px; background: var(--b-line); border-radius: 2px; overflow: hidden; margin: 8px 0 0; }
.progress > span { display: block; height: 100%; width: 0; background: var(--b-gold); transition: width 0.2s ease; }

@media (prefers-reduced-motion: reduce) {
  .login-drawing .draw { animation: none; stroke-dashoffset: 0; }
  .login-drawing .fade { animation: none; opacity: 0.8; }
  .progress > span { transition: none; }
}

/* Quote page: four pages, and the send window */
.q-top { margin-bottom: 8px; }
.q-top-extra { margin-top: 12px; }
.q-pager { display: flex; justify-content: space-between; gap: 10px; margin: 20px 0 8px; }
.q-modal { position: fixed; inset: 0; z-index: 60; background: rgba(0,0,0,0.62); display: flex; align-items: center; justify-content: center; padding: 12px; }
.q-modal-panel { width: min(1000px, 100%); height: min(94vh, 100%); background: var(--b-panel, #16181c); border: 1px solid var(--b-line); border-radius: var(--b-radius, 14px); display: flex; flex-direction: column; overflow: hidden; }
.q-modal-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 12px 14px; border-bottom: 1px solid var(--b-line); }
.q-modal-title { font-size: 16px; }
.q-modal-close { background: none; border: 0; color: var(--b-muted); font-size: 20px; cursor: pointer; padding: 6px 10px; }
.q-send-status:not(:empty) { padding: 12px 14px; border-bottom: 1px solid var(--b-line); }
.q-modal-body { flex: 1; min-height: 0; display: flex; flex-direction: column; overflow: auto; }
.q-modal-msg { padding: 10px 14px 0; }
.q-modal-msg .textarea { width: 100%; box-sizing: border-box; }
.q-modal-pdf { flex: 1; min-height: 320px; width: 100%; border: 0; background: #fff; margin-top: 10px; }
.q-qr-panel { display: flex; gap: 18px; align-items: flex-start; flex-wrap: wrap; }
.q-qr { width: 160px; height: 160px; background: #fff; padding: 4px; border-radius: 8px; flex: none; }
.q-qr svg { width: 100%; height: 100%; display: block; }
.q-steps { margin: 0 0 8px; padding-left: 20px; color: var(--b-muted); font-size: 14px; }
.q-dragchip { display: inline-block; margin: 6px 10px 6px 0; padding: 8px 12px; border: 1px dashed var(--b-gold); border-radius: 10px; color: var(--b-text); text-decoration: none; cursor: grab; font-size: 14px; }
.q-email-panel .input, .q-email-panel .textarea { width: 100%; box-sizing: border-box; margin-bottom: 8px; }
@media (max-width: 700px), (max-height: 500px) {
  .q-modal { padding: 0; }
  .q-modal-panel { height: 100%; border-radius: 0; border: 0; }
  .q-modal-head .button { flex: 1 1 auto; }
}

/* Import model | Import scan side by side, each with its import history. */
.import-title { margin: 0 0 16px; font-size: 20px; }
/* Insert page: one drop box per kind of file, and the folding sections below them. */
.import-boxes { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); }
.import-box { min-width: 0; display: grid; gap: 6px; align-content: start; position: relative; }
.import-box-title { margin: 0; font-size: 14px; font-weight: 700; }
.import-box .dropzone { min-height: 118px; padding: 14px 10px; }
.import-box .dz-title { font-size: 14px; }
.fold > summary { display: flex; align-items: center; gap: 10px; cursor: pointer; list-style: none; border-radius: 10px; }
.fold > summary::-webkit-details-marker { display: none; }
.fold > summary::before { content: ''; flex: none; width: 8px; height: 8px; margin: 0 4px 0 2px; border-right: 2px solid var(--b-gold); border-bottom: 2px solid var(--b-gold); transform: rotate(-45deg); transition: transform 0.15s ease; }
.fold[open] > summary::before { transform: rotate(45deg); }
.fold-title { margin: 0; flex: none; font-size: 16px; font-weight: 700; }
.fold-note { margin-left: auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; color: var(--b-muted); }
@media (max-width: 640px) { .fold > summary { flex-wrap: wrap; } .fold-note { flex-basis: 100%; margin-left: 24px; } }
@media (hover: hover) { .fold > summary:hover { box-shadow: 0 0 0 1.5px var(--b-gold), 0 0 10px color-mix(in srgb, var(--b-gold) 55%, transparent); } }
.fold > summary:focus-visible { outline: none; box-shadow: 0 0 0 1.5px var(--b-gold), 0 0 10px color-mix(in srgb, var(--b-gold) 55%, transparent); }
.import-history { margin-top: 22px; padding-top: 16px; border-top: 1px solid var(--b-line); }
.import-history-title { font-size: 0.8rem; letter-spacing: 0.08em; text-transform: uppercase; opacity: 0.7; margin: 0 0 8px; font-weight: 600; }
.import-history-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.import-history-list li { display: grid; gap: 2px; }
.import-history-name { overflow-wrap: anywhere; }
.import-history-meta { font-size: 0.85rem; opacity: 0.7; }

/* Text / WhatsApp / Email buttons carry the app's icon. */
.button.with-icon { display: inline-flex; align-items: center; gap: 8px; }
.button.with-icon img { width: 24px; height: 24px; border-radius: 6px; flex: none; }

/* Small icon buttons beside the project title: All projects and View Walkthrough. */
.tile-btn { display: inline-flex; align-items: center; justify-content: center; padding: 8px; border-radius: 12px; text-decoration: none;
  background: var(--b-panel); border: 1px solid var(--b-line); color: var(--b-text); font: inherit; cursor: pointer; flex: none; }
.tile-btn:hover { border-color: var(--b-gold); }
.tile-btn:focus-visible { outline: 2px solid var(--b-gold); outline-offset: 2px; }
.tile-btn.gold { color: var(--b-gold); }
.tile-btn .ico { display: block; line-height: 0; }
.tile-btn .ico svg { width: 24px; height: 24px; display: block; }


/* Clients: the people with access as chips (dot + name + when they last had it open). */
.member-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 12px; }
.member-chip { display: inline-flex; align-items: center; gap: 8px; padding: 7px 12px 7px 10px; border-radius: 999px; cursor: pointer;
  border: 1px solid var(--b-line); background: var(--b-panel-2); color: var(--b-text); font: inherit; font-size: 14px; text-align: left; }
.member-chip:hover { background-color: #23252b; }
.member-chip[aria-expanded="true"] { border-color: var(--b-gold); box-shadow: inset 0 0 0 1px var(--b-gold-deep); }
.member-chip .dot { width: 9px; height: 9px; border-radius: 50%; background: #6b6e76; flex: none; }
.member-chip.live .dot { background: #4cc38a; box-shadow: 0 0 0 3px rgba(76,195,138,0.25); }
.member-chip.recent .dot { background: var(--b-gold); }
.member-chip .nm { font-weight: 600; }
.member-chip .seen { font-size: 12px; color: var(--b-muted); }
.member-chip.live .seen { color: #4cc38a; }
.member-panel { display: grid; gap: 10px; margin: 0 0 16px; padding: 12px; border: 1px solid var(--b-line); border-radius: 14px; }
.member-panel .select { width: 100%; }

/* Invite a client: name, email and how long side by side so the chips below stay in view. */
.invite-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 0 12px; }

/* Schedules: each imported file with a tick; the ticked ones act as one complete schedule. */
.schedule-list { list-style: none; margin: 0 0 14px; padding: 0; }
.schedule-row { display: flex; gap: 12px; align-items: center; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid var(--b-line); }
.schedule-row.off .schedule-name { opacity: 0.5; }
.schedule-pick { display: flex; gap: 10px; align-items: flex-start; cursor: pointer; min-width: 0; }
.schedule-pick input { width: 20px; height: 20px; accent-color: var(--b-gold); margin: 2px 0 0; flex: none; }
.schedule-name { display: block; font-weight: 600; overflow-wrap: anywhere; }
.schedule-pick .meta { display: block; font-size: 13px; color: var(--b-muted); overflow-wrap: anywhere; }
/* One file, its two uses on one line under its name, and its buttons at the end. */
.schedule-one { flex-wrap: wrap; row-gap: 8px; }
.schedule-file { flex: 1 1 100%; min-width: 0; }
.schedule-file .meta { display: block; font-size: 13px; color: var(--b-muted); overflow-wrap: anywhere; }
.schedule-uses { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 20px; flex: 1 1 auto; min-width: 0; }
.schedule-one .schedule-pick { align-items: center; }
.schedule-one .schedule-pick input { margin: 0; }
.schedule-show, .schedule-stamp-edit { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.schedule-uses .select, .schedule-uses .input { width: auto; max-width: 100%; }
.schedule-btns { display: flex; gap: 8px; flex: none; }
.message.warn { background: rgba(201,169,97,0.14); color: #e3cf9f; }
.conflict-list { margin-top: 8px; font-size: 14px; }
.conflict-list summary { cursor: pointer; font-weight: 600; }
.conflict-list ul { margin: 8px 0 0; padding-left: 18px; display: grid; gap: 6px; }
.conflict-list .schedule-name { display: inline; }

/* Finishes: one row per part of the model, a finish from the library, one scale, Rich / Light. */
.finish-list { list-style: none; margin: 0 0 14px; padding: 0; }
.finish-row { display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap; padding: 8px 0; border-bottom: 1px solid var(--b-line); }
.finish-row.indent { padding-left: 14px; }
/* Quick assign rows: green once the whole group has a finish, amber when its surfaces differ, a gold ring on hover, focus and the row last used. */






@media (hover: hover) { }
/* The finish dropdown with pictures (js/finish-picker.js): a button with the chosen finish's picture and name; its list
   opens on a line of its own under the row's controls, each finish a picture and a name under its kind in bold. */
.fpk-btn { display: inline-flex; align-items: center; gap: 8px; min-height: 38px; flex: 1 1 150px; max-width: 280px; min-width: 150px; padding: 3px 10px 3px 4px; border-radius: 8px; border: 1px solid var(--b-line); background: var(--b-panel-2); color: var(--b-text); font: inherit; font-size: 14px; text-align: left; cursor: pointer; }
.fpk-btn:disabled { opacity: 0.55; cursor: default; }
.fpk-btn.empty .fpk-name { color: var(--b-muted); }
.fpk-btn[aria-expanded="true"] { border-color: var(--b-gold); }
.fpk-name { flex: 1; min-width: 0; overflow: hidden; font-size: 13px; line-height: 1.15; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; overflow-wrap: anywhere; }
.fpk-btn.empty { padding-left: 10px; }
.fpk-caret { flex: none; font-size: 12px; opacity: 0.7; }
.fpk-slot { display: contents; }
.fpk-thumb { flex: none; width: 40px; height: 40px; border-radius: 6px; overflow: hidden; display: block; background: #3a3f47; border: 1px solid rgba(255,255,255,0.18); }
.fpk-btn .fpk-thumb { width: 30px; height: 30px; }
.fpk-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.fpk-thumb.orig { background: repeating-linear-gradient(135deg, #2c3037 0 6px, #343941 6px 12px); }
.fpk-thumb.none { display: none; }
.fpk-list { flex: 1 1 100%; order: 8; display: grid; gap: 6px; padding: 8px; border: 1px solid var(--b-gold); border-radius: 10px; background: var(--b-panel); box-shadow: 0 8px 24px rgba(0,0,0,0.35); }
.fpk-list[hidden] { display: none; }
.finish-controls:has(> .fpk-list:not([hidden])) { flex: 1 1 100%; }
.fpk-search { min-height: 36px; padding: 6px 10px; font-size: 14px; }
.fpk-box { max-height: 320px; overflow-y: auto; display: flex; flex-direction: column; gap: 4px; padding-right: 2px; }
.fpk-group { margin: 8px 2px 2px; font-size: 13px; font-weight: 700; color: var(--b-gold); }
.fpk-group:first-child { margin-top: 2px; }
.fpk-opt { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 48px; padding: 4px 8px 4px 4px; border-radius: 8px; border: 1px solid transparent; background: rgba(255,255,255,0.04); color: var(--b-text); font: inherit; font-size: 14px; text-align: left; cursor: pointer; }
.fpk-opt.on { border-color: var(--b-gold); background: rgba(201,169,97,0.14); }
@media (hover: hover) { .fpk-btn:not(:disabled):hover, .fpk-opt:hover { border-color: var(--b-gold); box-shadow: 0 0 0 2px rgba(201,169,97,0.3); } }
.fpk-btn:focus-visible, .fpk-opt:focus-visible { outline: 2px solid var(--b-gold); outline-offset: 1px; }
.fpk-empty { margin: 6px 4px; font-size: 13px; color: var(--b-muted); }
/* A finish's colour and direction (js/finish-adjust.js): Original, colour dots, an any-colour picker; As is / Turned 90°. */
.fa-colours, .fa-turns { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.fa-swatch { width: 26px; height: 26px; padding: 0; border-radius: 50%; border: 1px solid rgba(255,255,255,0.35); cursor: pointer; flex: none; }
.fa-any { width: 34px; height: 28px; padding: 1px 2px; border-radius: 8px; border: 1px solid rgba(255,255,255,0.35); background: transparent; cursor: pointer; flex: none; }
.fa-swatch[aria-pressed="true"], .fa-any.on { box-shadow: 0 0 0 2px #15171b, 0 0 0 4px var(--b-gold, #c9a961); }
.fa-orig, .fa-turn { min-height: 30px; padding: 0 11px; border-radius: 999px; border: 1px solid rgba(255,255,255,0.2); background: rgba(255,255,255,0.06); color: inherit; font: inherit; font-size: 13px; cursor: pointer; }
.fa-orig[aria-pressed="true"], .fa-turn[aria-checked="true"] { background: rgba(201,169,97,0.22); border-color: var(--b-gold, #c9a961); color: var(--b-gold, #c9a961); }
@media (hover: hover) { .fa-swatch:hover, .fa-any:hover, .fa-orig:hover, .fa-turn:hover { border-color: var(--b-gold, #c9a961); box-shadow: 0 0 0 2px rgba(201,169,97,0.3); } }
.fa-swatch:focus-visible, .fa-any:focus-visible, .fa-orig:focus-visible, .fa-turn:focus-visible { outline: 2px solid var(--b-gold, #c9a961); outline-offset: 2px; }
.fa-cap { font-size: 12px; opacity: 0.75; margin: 4px 0 2px; }
.fa-scales { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; }
.fa-scale { width: 86px; min-height: 34px; padding: 4px 8px; }
/* Quick assign: a colour dot that folds open to the swatches (full row width while open). */




@media (hover: hover) { }



.finish-name { font-weight: 600; overflow-wrap: anywhere; min-width: 140px; flex: 1 1 200px; }
.finish-controls { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.finish-controls .select { width: auto; max-width: 240px; min-height: 38px; padding: 6px 10px; }






.old-materials summary { cursor: pointer; font-weight: 600; padding: 6px 0; }
.old-materials { margin-top: 8px; }

/* Finishes checklist: surfaces with and without a finish. */
.finish-summary { margin: 0 0 8px; padding: 10px 12px; border-radius: var(--b-radius-sm); background: rgba(201,169,97,0.12); color: #e3cf9f; font-size: 14px; }
.finish-summary.all { background: rgba(159,191,143,0.12); color: #c3dcb7; }



.finish-note { display: block; font-size: 12px; font-weight: 400; color: #e3cf9f; }
.finish-cat { margin: 6px 0; border: 1px solid var(--b-line); border-radius: 12px; padding: 4px 12px; }
.finish-cat > summary { cursor: pointer; font-weight: 600; padding: 8px 0; }



/* Project page: the name with All projects and View Walkthrough beside it, then the tabs. */



@media (max-width: 700px), (max-height: 500px) { }

/* Dashboard summary and rounded cards (admin). */
.stat-grid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); margin: 0 0 20px; }
.stat-card { display: grid; gap: 4px; align-content: start; padding: 16px 18px; background: var(--b-panel); border: 1px solid var(--b-line); border-radius: 16px; color: var(--b-text); text-decoration: none; }
a.stat-card { transition: box-shadow 0.14s ease, border-color 0.14s ease; }
@media (hover: hover) { a.stat-card:hover { border-color: var(--b-gold); box-shadow: 0 0 0 1.5px var(--b-gold), 0 0 10px color-mix(in srgb, var(--b-gold) 55%, transparent); } }
a.stat-card:focus-visible { outline: 2px solid var(--b-gold); outline-offset: 2px; }
.stat-wide { grid-column: 1 / -1; }
@media (min-width: 900px) { .stat-wide { grid-column: span 2; } }
.stat-label { font-size: 12px; font-weight: 600; letter-spacing: 0.05em; text-transform: uppercase; color: var(--b-muted); }
.stat-value { font-size: 30px; font-weight: 700; line-height: 1.15; }
.stat-note { font-size: 13px; color: var(--b-muted); }
.stage-counts { display: flex; gap: 22px; flex-wrap: wrap; }
.stage-count { display: grid; }
.card { background: var(--b-panel); border: 1px solid var(--b-line); border-radius: 16px; padding: 6px 12px; }
.admin .section { background: var(--b-panel); border: 1px solid var(--b-line); border-radius: 16px; padding: 20px; margin-bottom: 16px; }
.admin .section:last-child { border-bottom: 1px solid var(--b-line); }
.admin .section .section, .admin .fold .section { background: none; border: 0; border-radius: 0; padding: 0; margin-bottom: 0; }
.admin .fold { border-top: 1px solid var(--b-line); }
.admin .fold > summary { padding: 13px 8px; }
.admin .fold > .fold-body { padding: 4px 8px 18px; }
.admin .import-group { background: var(--b-panel); border: 1px solid var(--b-line); border-radius: 16px; padding: 20px; margin-bottom: 16px; }

/* ---------- client dashboard (dashboard.html) ---------- */
.dash { min-height: 100dvh; display: flex; flex-direction: column; align-items: center; gap: 24px; padding: max(28px, env(safe-area-inset-top)) 16px 32px; }
.dash-body { width: 100%; max-width: 640px; }
.dash-open { margin: 22px 0; min-height: 60px; font-size: 18px; }

.dash-card { background: var(--b-panel); border: 1px solid var(--b-line); border-radius: var(--b-radius); padding: 18px; }
.dash-h { margin: 0 0 8px; font-size: 13px; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; color: var(--b-muted); }
.dash-big { margin: 0; font-size: 30px; font-weight: 700; line-height: 1.2; }
.dash-meta { margin: 2px 0 0; font-size: 13px; color: var(--b-muted); }
.dash-status { margin: 8px 0 4px; font-weight: 600; color: var(--b-gold); }
.dash-docs { list-style: none; margin: 0; padding: 0; }
.dash-doc { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 0; border-top: 1px solid var(--b-line); }
.dash-doc:first-child { border-top: 0; padding-top: 4px; }
.dash-doc-text { display: grid; gap: 2px; min-width: 0; }
.dash-doc-title { font-weight: 600; overflow-wrap: anywhere; }

/* Client Walkthrough button beside the project name. */



@media (hover: hover) { }

@media (max-width: 700px), (max-height: 500px) { }

/* The "i" next to a title: bold yellow, bubble with the instructions on hover / focus / tap. */
.info-wrap { display: inline-block; vertical-align: middle; margin-left: 6px; }
.info-i { height: 24px; padding: 0 10px 0 4px; gap: 6px; border-radius: 999px; border: 0; background: var(--b-gold); color: #1b1710;
  font: inherit; font-size: 13px; font-weight: 700; font-style: normal; line-height: 1; letter-spacing: 0; text-transform: none; cursor: help; display: inline-flex; align-items: center; }
.info-dot { width: 16px; height: 16px; border-radius: 50%; background: #1b1710; color: var(--b-gold); display: inline-flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; }
.info-i:hover, .info-wrap.show .info-i { background: #dcc283; }
.info-i:focus-visible { outline: 2px solid var(--b-gold); outline-offset: 2px; }
.info-tip { display: none; position: fixed; z-index: 90; padding: 12px 14px; border-radius: 12px; background: var(--b-panel-2); border: 1px solid var(--b-gold-deep);
  box-shadow: 0 12px 32px rgba(0,0,0,0.5); color: var(--b-text); font-size: 14px; font-weight: 400; font-style: normal; line-height: 1.45;
  letter-spacing: 0; text-transform: none; text-align: left; white-space: normal; }
.info-wrap.show .info-tip { display: block; }

/* Project tabs: one rounded bar, icon left of the name, the open tab raised with a gold edge. */
.admin-tabs.bar-tabs { width: max-content; max-width: 100%; gap: 2px; padding: 4px; margin: 0 0 22px; background: var(--b-panel); border: 1px solid var(--b-line); border-radius: 14px; }
.admin-tabs.bar-tabs button { display: inline-flex; align-items: center; gap: 9px; flex: none; margin: 0; padding: 9px 14px; border: 0; border-radius: 10px; color: var(--b-muted); }
.admin-tabs.bar-tabs button:hover { color: var(--b-text); }
.admin-tabs.bar-tabs button[aria-selected="true"] { color: var(--b-text); background: #2e333b; box-shadow: inset 0 -2px 0 var(--b-gold); }
.admin-tabs.bar-tabs button:focus-visible { outline: 2px solid var(--b-gold); outline-offset: -2px; }
.admin-tabs.bar-tabs .ico { display: block; line-height: 0; flex: none; }
.admin-tabs.bar-tabs .ico svg { width: 22px; height: 22px; display: block; }


/* File pickers as drop areas (js/admin-ui.js enhanceFileInputs). The real input stays, hidden. */
input.dz-native { position: absolute; width: 1px; height: 1px; opacity: 0; overflow: hidden; pointer-events: none; }
.dropzone { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; text-align: center; min-height: 128px; padding: 18px 14px; cursor: pointer;
  border: 2px dashed #4a505a; border-radius: 14px; background: var(--b-page); transition: border-color 0.14s ease, background 0.14s ease, box-shadow 0.14s ease; position: relative; }
.dropzone .dz-icon { display: block; line-height: 0; color: var(--b-gold); }
.dropzone .dz-icon svg { width: 34px; height: 34px; display: block; }
.dropzone .dz-text { display: grid; gap: 2px; min-width: 0; max-width: 100%; }
.dropzone .dz-title { font-size: 15px; font-weight: 600; overflow-wrap: anywhere; }
.dropzone .dz-sub { font-size: 13px; color: var(--b-muted); }
.dropzone .dz-clear { display: none; position: absolute; top: 8px; right: 8px; width: 28px; height: 28px; padding: 0; border: 0; border-radius: 50%; background: var(--b-panel-2); color: var(--b-muted); font-size: 18px; line-height: 1; cursor: pointer; }
.dropzone .dz-clear:hover { color: var(--b-text); }
.dropzone.has-file { border-style: solid; border-color: var(--b-gold); background: rgba(201,169,97,0.07); }
.dropzone.has-file .dz-clear { display: block; }
.dropzone.drag { border-color: var(--b-gold); background: rgba(201,169,97,0.12); box-shadow: 0 0 0 1.5px var(--b-gold); }
@media (hover: hover) { .dropzone:hover { border-color: var(--b-gold); box-shadow: 0 0 0 1.5px var(--b-gold), 0 0 10px color-mix(in srgb, var(--b-gold) 55%, transparent); } }
.dropzone:focus-visible { outline: 2px solid var(--b-gold); outline-offset: 2px; }

/* Slim, modern scrollbars (the chunky old ones are gone). */
:where(.portal-page, .portal-page *) { scrollbar-width: thin; scrollbar-color: rgba(255,255,255,0.28) transparent; }
:where(.portal-page) ::-webkit-scrollbar { width: 8px; height: 8px; }
:where(.portal-page) ::-webkit-scrollbar-track { background: transparent; }
:where(.portal-page) ::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.24); border-radius: 8px; border: 2px solid transparent; background-clip: padding-box; }
:where(.portal-page) ::-webkit-scrollbar-thumb:hover { background: rgba(201,169,97,0.7); background-clip: padding-box; }

/* ---------- the Comments board (js/portal/board.js): a rolling feed, newest at the bottom ---------- */
.board { display: flex; flex-direction: column; min-height: 0; height: 100%; font-family: var(--b-font); color: var(--b-text); font-size: 14px; position: relative; }
.board *, .board *::before, .board *::after { box-sizing: border-box; }
.board-bar { display: flex; gap: 6px; flex-wrap: wrap; padding: 2px 0 10px; }
.board-chip { padding: 5px 13px; border-radius: 999px; border: 1px solid var(--b-line); background: none; color: var(--b-muted); font: 600 12.5px inherit; cursor: pointer; }
.board-chip:hover { color: var(--b-text); }
.board-chip.on { background: rgba(201,169,97,0.2); border-color: var(--b-gold); color: var(--b-gold); }
.board-feed { flex: 1 1 auto; min-height: 120px; overflow-y: auto; display: flex; flex-direction: column; gap: 10px; padding: 2px 2px 8px; overscroll-behavior: contain; }
.board-more { align-self: center; padding: 5px 14px; border-radius: 999px; border: 1px solid var(--b-line); background: none; color: var(--b-muted); font: 600 12px inherit; cursor: pointer; }
.board-empty { color: var(--b-muted); margin: 20px 6px; text-align: center; }
.board-card { background: var(--b-panel-2); border: 1px solid var(--b-line); border-radius: 14px; padding: 11px 12px; display: flex; flex-direction: column; gap: 7px; }
.board-card.resolved { opacity: 0.72; }
.board-card.focus { border-color: var(--b-gold); box-shadow: 0 0 0 2px rgba(201,169,97,0.45); }
.board-card.in { animation: boardIn 0.32s cubic-bezier(0.16, 1, 0.3, 1); }
@keyframes boardIn { from { opacity: 0; transform: translateY(22px) scale(0.98); } }
.board-head { display: flex; align-items: center; gap: 9px; }
.board-who { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; min-width: 0; flex: 1; }
.board-av { width: 30px; height: 30px; border-radius: 50%; flex: none; display: inline-flex; align-items: center; justify-content: center; color: #fff; font-weight: 800; font-size: 13px; }
.board-av.sm { width: 22px; height: 22px; font-size: 12px; }
.board-badge { font-size: 12px; font-weight: 800; padding: 1px 7px; border-radius: 999px; background: rgba(201,169,97,0.2); color: var(--b-gold); }
.board-time { color: var(--b-muted); font-size: 12px; }
.board-status { margin-left: auto; font-size: 12px; font-weight: 700; padding: 2px 9px; border-radius: 999px; background: rgba(159,191,143,0.15); color: var(--b-ok); border: 1px solid rgba(159,191,143,0.5); }
.board-body { white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.45; }
.board-context { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.board-pill { font-size: 12px; font-weight: 700; padding: 2px 9px; border-radius: 999px; border: 1px solid var(--b-gold-deep); color: var(--b-gold); }
.board-go { background: none; border: 0; padding: 0; color: var(--b-gold); font: 700 12.5px inherit; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.board-actions { display: flex; gap: 14px; flex-wrap: wrap; }
.board-act { background: none; border: 0; padding: 2px 0; color: var(--b-muted); font: 600 12.5px inherit; cursor: pointer; }
.board-act:hover { color: var(--b-text); }
.board-replies { margin-left: 14px; padding-left: 11px; border-left: 2px solid var(--b-line); display: flex; flex-direction: column; gap: 9px; }
.board-reply { display: flex; gap: 8px; align-items: flex-start; }
.board-reply-main { min-width: 0; flex: 1; display: flex; flex-direction: column; gap: 3px; }
.board-latest { position: absolute; left: 50%; bottom: 96px; transform: translateX(-50%); padding: 6px 14px; border-radius: 999px; border: 1px solid var(--b-gold); background: var(--b-panel); color: var(--b-gold); font: 700 12.5px inherit; cursor: pointer; box-shadow: 0 8px 24px rgba(0,0,0,0.45); z-index: 2; }
.board-latest[hidden], .board-error[hidden] { display: none; }
.board-error { margin: 4px 0; padding: 7px 10px; border-radius: 10px; background: rgba(224,138,118,0.14); color: #f0b4a5; font-size: 13px; }
.board-compose { border-top: 1px solid var(--b-line); padding-top: 9px; display: flex; flex-direction: column; gap: 6px; }
.board-input-row { display: flex; gap: 8px; align-items: flex-end; }
.board-input, .board-edit { flex: 1; min-width: 0; resize: none; padding: 9px 12px; border-radius: 12px; border: 1px solid var(--b-line); background: var(--b-panel-2); color: var(--b-text); font: inherit; font-size: 14px; line-height: 1.35; }
.board-input:focus, .board-edit:focus { outline: none; border-color: var(--b-gold); }
.board-post { flex: none; min-height: 38px; padding: 0 16px; border-radius: 999px; border: 0; background: var(--b-gold); color: #1b1710; font: 800 13px inherit; cursor: pointer; }
.board-post:disabled { opacity: 0.4; cursor: default; }
.board-edit-row { display: flex; gap: 8px; align-items: flex-start; flex-wrap: wrap; }
.board-compose-foot { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; font-size: 12.5px; color: var(--b-muted); }
.board-attach { display: inline-flex; align-items: center; gap: 6px; cursor: pointer; }
.board-attach input { accent-color: var(--b-gold); }
.board-pin-btn { background: none; border: 1px solid var(--b-line); border-radius: 999px; padding: 3px 11px; color: var(--b-text); font: 600 12px inherit; cursor: pointer; }
.board-pin-btn:hover { border-color: var(--b-gold); }
.board-count.warn { color: var(--b-gold); }

/* The client dashboard, wide: the comments board in the main column, drawings and the quote at the side. */
.dash-body.dash-wide { max-width: 1100px; }
.dash-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.dash-top-actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.dash-top-actions .dash-open { width: auto; margin: 0; min-height: 52px; padding: 0 26px; font-size: 16px; }
.dash-top-actions .dash-call { min-height: 52px; padding: 0 20px; font-size: 15px; }

@media (min-width: 900px) { }



.dash-board { height: min(68vh, 640px); min-height: 380px; display: flex; flex-direction: column; }
.dash-board .board { flex: 1 1 auto; min-height: 0; }

/* The board in the walkthrough's bubble style (the dashboard): small rounded messages, a pill to type in. */
.board.bubbles .board-feed { gap: 6px; }
.board.bubbles .board-card { background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.09); border-radius: 14px; padding: 7px 12px 7px 8px; gap: 3px; }
.board.bubbles .board-card.resolved { opacity: 0.6; }
.board.bubbles .board-head .board-av { width: 22px; height: 22px; font-size: 12px; }
.board.bubbles .board-who b { font-weight: 800; font-size: 13px; }
.board.bubbles .board-time { font-size: 12px; }
.board.bubbles .board-body { font-size: 13px; line-height: 1.35; text-shadow: 0 1px 2px rgba(0,0,0,0.5); padding-left: 30px; }
.board.bubbles .board-context, .board.bubbles .board-actions { padding-left: 30px; }
.board.bubbles .board-replies { margin-left: 30px; border-left-color: rgba(255,255,255,0.12); }
.board.bubbles .board-input { height: 38px; min-height: 38px; padding: 0 14px; border-radius: 999px; background: rgba(255,255,255,0.07); border-color: rgba(255,255,255,0.18); line-height: 36px; }
.board.bubbles .board-post { height: 38px; border-radius: 999px; padding: 0 18px; }
.board.bubbles .board-compose { border-top: 0; padding-top: 6px; }
.board.bubbles .board-chip { font-size: 12px; padding: 4px 12px; background: rgba(255,255,255,0.05); border-color: rgba(255,255,255,0.12); }
.board.bubbles .board-chip.on { background: rgba(201,169,97,0.2); border-color: var(--b-gold); }

.doc-actions { display: inline-flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.file-list li > .doc-name { flex: 1 1 200px; min-width: 0; }

/* The light version of a drawing, full screen (js/portal/sheet-view.js): pale line sheets on a dark page. */
.svf { position: fixed; inset: 0; z-index: 300; display: flex; flex-direction: column; background: #2a2d33; color: var(--b-text); font-family: var(--b-font); }
body.svf-open { overflow: hidden; }
.svf-bar { display: flex; align-items: center; gap: 8px; padding: 8px 12px; padding-top: max(8px, env(safe-area-inset-top)); border-bottom: 1px solid var(--b-line); background: var(--b-panel); flex-wrap: wrap; }
.svf-title { font-weight: 700; font-size: 15px; overflow-wrap: anywhere; min-width: 0; }
.svf-count { color: var(--b-muted); font-size: 12.5px; font-variant-numeric: tabular-nums; margin-right: 4px; }
.svf-btn { min-width: 36px; height: 36px; padding: 0 11px; border-radius: 10px; border: 1px solid var(--b-line); background: var(--b-panel-2); color: var(--b-text); font: 700 16px inherit; cursor: pointer; }
.svf-btn.wide { font-size: 13px; }
.svf-btn.pct { font-size: 12.5px; min-width: 58px; font-variant-numeric: tabular-nums; }
.svf-btn:hover:not(:disabled), .svf-btn[aria-pressed="true"] { border-color: var(--b-gold); }
.svf-btn:disabled { opacity: 0.4; cursor: default; }
.svf-btn:focus-visible { outline: 2px solid var(--b-gold); outline-offset: 2px; }
.svf-body { flex: 1 1 auto; min-height: 0; display: flex; }
.svf-stagewrap { position: relative; flex: 1 1 auto; min-width: 0; }
.svf-stage { position: absolute; inset: 0; overflow: hidden; touch-action: none; cursor: grab; outline: none; user-select: none; -webkit-user-select: none; }
.svf-stage.panning { cursor: grabbing; }
.svf-world { position: absolute; left: 0; top: 0; transform-origin: 0 0; display: flex; flex-direction: column; gap: 14px; will-change: transform; }
.svf-sheet { position: relative; width: 100%; min-height: 160px; border: 0; border-radius: 2px; background: #ffffff; box-shadow: 0 6px 22px rgba(0,0,0,0.45); }   /* paper */
.svf-img { display: block; width: 100%; height: auto; filter: invert(1); opacity: 0;   /* the pictures are pale lines on clear; inverted they are black lines on the white paper */ transition: opacity 0.2s ease; pointer-events: none; -webkit-user-drag: none; }
.svf-sheet.ready .svf-img { opacity: 1; }
.svf-sheet.ready .svf-wait { display: none; }
.svf-wait { position: absolute; inset: 0; display: grid; place-items: center; color: #6b7078; font-size: 13px; text-align: center; padding: 10px; }
.svf-hint { position: absolute; left: 50%; bottom: 14px; transform: translateX(-50%); padding: 6px 14px; border-radius: 999px; background: rgba(14,15,18,0.8); color: var(--b-muted); font-size: 12px; pointer-events: none; transition: opacity 0.6s ease; white-space: nowrap; max-width: 92%; overflow: hidden; text-overflow: ellipsis; }
.svf-hint.gone { opacity: 0; }
.svf-side { flex: none; width: 380px; max-width: 42vw; border-left: 1px solid var(--b-line); background: var(--b-panel); padding: 12px; display: flex; flex-direction: column; min-height: 0; }
.svf-side > * { flex: 1 1 auto; min-height: 0; }
.svf.side-off .svf-side { display: none; }
@media (max-width: 900px) { .svf-side { position: absolute; right: 0; top: 0; bottom: 0; width: min(380px, 92vw); max-width: none; z-index: 2; box-shadow: -12px 0 30px rgba(0,0,0,0.5); } .svf-body { position: relative; } }

.dash-doc-actions { display: inline-flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }




/* The sheet list in the full-screen light view. */
.svf-list { flex: none; width: 240px; border-right: 1px solid var(--b-line); background: var(--b-panel); display: flex; flex-direction: column; min-height: 0; overflow: hidden; }
.svf-list-top { flex: 1 1 auto; min-height: 0; overflow-y: auto; padding: 8px; display: flex; flex-direction: column; gap: 4px; }
/* with the chat docked under the names: names on the top two thirds, chat on the lower third */
.svf-list.has-foot { width: 320px; }
.svf-list.has-foot .svf-list-top { flex: 2 1 0; }
.svf-list-foot { flex: 1 1 0; min-height: 0; border-top: 1px solid var(--b-line); display: flex; flex-direction: column; }
html:not(.props-docked) .lc.dc.docked, .lc.dc.docked { position: static; left: auto; bottom: auto; width: auto; flex: 1 1 auto; min-height: 0; padding: 8px; box-sizing: border-box; z-index: auto; }
.lc.dc.docked > .lc-list { flex: 1 1 auto; min-height: 0; overflow-y: auto; justify-content: flex-end; pointer-events: auto; align-items: stretch; }
.lc.dc.docked .lc-msg { max-width: 100%; }
.lc.dc.docked .lc-item { max-width: 100%; }
.lc.dc.docked.folded { flex: none; }
.svf.list-off .svf-list { display: none; }
.svf-row { display: flex; align-items: flex-start; gap: 9px; width: 100%; text-align: left; padding: 8px 10px; border-radius: 10px; border: 1px solid transparent; background: none; color: var(--b-text); font: 600 13px/1.3 var(--b-font); cursor: pointer; }
.svf-row:hover { background: rgba(255,255,255,0.06); }
.svf-row.on { background: rgba(201,169,97,0.16); border-color: var(--b-gold); color: var(--b-gold); }
.svf-rownum { flex: none; min-width: 22px; height: 22px; padding: 0 6px; box-sizing: border-box; white-space: nowrap; display: inline-grid; place-items: center; border-radius: 6px; background: rgba(255,255,255,0.08); font-size: 12px; font-variant-numeric: tabular-nums; }
.svf-rowname { overflow-wrap: anywhere; min-width: 0; }
@media (max-width: 900px) {
  .svf-list { position: absolute; left: 0; top: 0; bottom: 0; z-index: 3; width: min(280px, 86vw); transform: translateX(-102%); transition: transform 0.2s ease; box-shadow: 12px 0 30px rgba(0,0,0,0.5); }
  .svf-list.open { transform: none; }
  .svf.list-off .svf-list { display: flex; }
}

/* Zoomed in far: the visible part of a sheet is drawn again, sharp, from the PDF. */
.svf-sharp { position: absolute; display: block; background: #fff; pointer-events: none; }
.svf-hint.busy { opacity: 1; color: var(--b-gold); }

/* Live links between sheets in the light view: the callouts you can click, and the gold ring where you land. */
.svf-link { position: absolute; display: block; padding: 0; margin: 0; border: 2px solid #b8860b; border-radius: 8px; background: rgba(201,169,97,0.14); filter: drop-shadow(0 0 3px rgba(184,134,11,0.6)); cursor: pointer; z-index: 2; transition: background 0.12s ease, box-shadow 0.12s ease; }
.svf-link:hover, .svf-link:focus-visible { background: rgba(201,169,97,0.24); box-shadow: 0 0 0 2px #c9a961, 0 0 12px rgba(201,169,97,0.7); outline: none; }
.svf.links-off .svf-link:not(:hover):not(:focus-visible) { border-color: transparent; background: transparent; }
.svf-goback { position: absolute; left: 50%; bottom: 56px; transform: translateX(-50%); z-index: 5; display: flex; flex-direction: column; align-items: center; gap: 1px; max-width: 92%;
  padding: 10px 22px; border-radius: 14px; border: 0; background: var(--b-gold); color: #1b1710; font: 700 15px var(--b-font); cursor: pointer; box-shadow: 0 10px 30px rgba(0,0,0,0.5); animation: svfGobackIn 0.25s ease-out; }
.svf-goback:hover { background: #d6b874; box-shadow: 0 0 0 2px var(--b-gold), 0 10px 30px rgba(0,0,0,0.5); }
.svf-goback:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.svf-goback-name { font: 600 12px var(--b-font); opacity: 0.8; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.svf-goback[hidden] { display: none; }
@keyframes svfGobackIn { from { opacity: 0; transform: translate(-50%, 12px); } }
.svf-ring { position: absolute; pointer-events: none; z-index: 3; border: 3px solid #c9a961; border-radius: 8px; box-shadow: 0 0 0 4px rgba(201,169,97,0.35), 0 0 26px rgba(201,169,97,0.85); animation: svfRing 2.8s ease-out forwards; }
@keyframes svfRing { 0%, 55% { opacity: 1; } 100% { opacity: 0; } }
.svf-btn[hidden] { display: none; }

.svf-btn.svf-icon { width: 38px; padding: 0; display: inline-grid; place-items: center; }
.svf-btn.svf-icon svg { width: 20px; height: 20px; display: block; }
.svf-btn:hover:not(:disabled) { box-shadow: 0 0 0 1.5px var(--b-gold), 0 0 10px rgba(201,169,97,0.5); }

/* Bella look for the light view: icon tiles, a Find box over the sheet list, a bottom dock on phones. */
.svf-tools { display: flex; align-items: center; gap: 6px; }
.svf-btn.svf-icon { color: var(--b-text); }
.svf-btn[aria-pressed="false"] { color: var(--b-muted); }
.svf-btn[aria-pressed="true"]:not(.pct) { color: var(--b-gold); }
.svf-word { display: none; }
.svf-btn.svf-icon svg { width: 20px; height: 20px; }
.svf-btn.svf-zoomb.svf-icon { width: 34px; }
.svf-btn.svf-scroll { white-space: nowrap; }
.svf-find { width: 100%; box-sizing: border-box; height: 36px; margin-bottom: 4px; padding: 0 10px; border-radius: 10px; border: 1px solid var(--b-line); background: var(--b-panel-2); color: var(--b-text); font: 600 13px var(--b-font); outline: none; }
.svf-find:focus { border-color: var(--b-gold); box-shadow: 0 0 0 1.5px var(--b-gold), 0 0 10px rgba(201,169,97,0.4); }
.svf-row[hidden], .svf-nomatch[hidden] { display: none; }
.svf-nomatch { color: var(--b-muted); font-size: 12.5px; padding: 8px 10px; }
@media (hover: hover) { .svf-row:hover { border-color: var(--b-gold); box-shadow: 0 0 0 1px var(--b-gold), 0 0 8px rgba(201,169,97,0.35); background: none; } }
.svf-row:focus-visible { outline: none; border-color: var(--b-gold); box-shadow: 0 0 0 1.5px var(--b-gold), 0 0 10px rgba(201,169,97,0.4); }
@media (max-width: 700px), (max-height: 500px) {
  .svf-count, .svf-tools .svf-zoomb { display: none; }
  .svf-tools { position: fixed; left: 0; right: 0; bottom: 0; z-index: 6; justify-content: space-around; gap: 0; padding: 6px 6px max(6px, env(safe-area-inset-bottom)); background: var(--b-panel); border-top: 1px solid var(--b-line); }
  .svf-tools .svf-btn { flex-direction: column; gap: 2px; width: auto; min-width: 58px; height: 48px; border-color: transparent; background: none; font-size: 12px; }
  .svf-tools .svf-btn:hover:not(:disabled) { box-shadow: none; }
  .svf-tools .svf-word { display: block; font: 600 12px var(--b-font); }
  .svf-bar .svf-btn .svf-word { display: none; }
  .svf-stagewrap { padding-bottom: 62px; }
  .svf-goback { bottom: 76px; }
  .svf-hint { bottom: 76px; }
  .svf-list { bottom: 62px; }
  .svf-side { bottom: 62px; }
}

/* ---- The client dashboard as two pages behind icon tiles (js/client-dashboard.js) ---- */
.dash-tabs { display: flex; align-items: center; gap: 8px; margin-top: 16px; flex-wrap: wrap; }
.dash-tab { display: inline-flex; align-items: center; gap: 9px; height: 46px; padding: 0 14px; border-radius: 12px; border: 1px solid var(--b-line); background: var(--b-panel-2); color: var(--b-text); font: 700 14px var(--b-font); cursor: pointer; }
.dash-tab-ico { width: 24px; height: 24px; display: grid; place-items: center; flex: none; }
.dash-tab-ico svg { width: 22px; height: 22px; display: block; }
.dash-tab.on { border-color: var(--b-gold); color: var(--b-gold); background: rgba(201,169,97,0.12); }
@media (hover: hover) { .dash-tab:hover { border-color: var(--b-gold); box-shadow: 0 0 0 1px var(--b-gold), 0 0 10px rgba(201,169,97,0.35); } }
.dash-tab:focus-visible { outline: none; border-color: var(--b-gold); box-shadow: 0 0 0 1.5px var(--b-gold), 0 0 10px rgba(201,169,97,0.4); }
.dash-quote { display: inline-flex; align-items: baseline; gap: 8px; height: 46px; padding: 0 14px; align-items: center; border-radius: 12px; border: 1px solid var(--b-line); background: var(--b-panel); font-size: 13px; }
.dash-quote-label { color: var(--b-muted); text-transform: uppercase; letter-spacing: 0.04em; font-size: 12px; font-weight: 600; }
.dash-quote b { font-size: 16px; }
.dash-quote-status { color: var(--b-gold); font-weight: 600; }
.dash-page { margin-top: 14px; }
.dash-viewer { height: calc(100dvh - 330px); min-height: 460px; }
/* The phone's More: features that live on a computer, a little gray, with the names easy to read (js/portal/on-computer.js). */
.computer-box { padding: 10px 0 6px; }
.computer-h { display: flex; align-items: center; gap: 6px; margin-bottom: 8px; font-size: 13px; font-weight: 600; opacity: 0.8; }
.computer-mark, .computer-mark svg { display: block; width: 18px; height: 18px; }
.computer-tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.computer-tile { display: flex; flex-direction: column; align-items: center; gap: 4px; min-width: 0; padding: 8px 2px; border: 1px solid rgba(255,255,255,0.1); border-radius: 10px; background: none; color: inherit; font: inherit; font-size: 11.5px; line-height: 1.15; text-align: center; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.computer-ico { opacity: 0.5; }
.computer-ico svg { display: block; width: 26px; height: 26px; }
.computer-line { margin: 0 0 12px; }
.computer-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.computer-actions .portal-button { width: auto; margin: 0; padding: 0 18px; }
/* The phone's bottom bar on the dashboard (js/portal/phone-bar.js), the same six buttons as in the walkthrough. */
.phone-bar, .dash-phone-comments { display: none; }
@media (max-width: 700px), (max-height: 500px) {
  .phone-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; display: flex; padding: 4px 4px calc(4px + env(safe-area-inset-bottom)); background: var(--b-panel); border-top: 1px solid var(--b-line); }
  .phone-bar-btn { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 4px 0 5px; border: 0; border-radius: 12px; background: none; color: var(--b-text); font: inherit; font-size: 11.5px; line-height: 1.15; text-decoration: none; cursor: pointer; -webkit-tap-highlight-color: transparent; }
  .phone-bar-btn svg { display: block; width: 27px; height: 27px; }
  .phone-bar-btn.on { color: var(--b-gold); }
  .phone-bar-tools { position: relative; margin-left: 7px; }
  .phone-bar-tools::before { content: ''; position: absolute; left: -4px; top: 18%; bottom: 18%; width: 1px; background: var(--b-gold); opacity: 0.6; }
  /* One navigation: no Full screen with a bar of its own, and the admin's Drawings and Walkthrough tiles are in the bar. */
  body.has-phone-bar .svf-expand, body.has-phone-bar .proj-tiles { display: none; }
  body.has-phone-bar .admin { padding-bottom: 76px; }
  body.has-phone-bar .dash-viewer, body.has-phone-bar.proj-mode .dash-viewer { min-height: 320px; height: calc(100dvh - var(--dock-h, 68px) - 150px); }
  .phone-more-row { display: block; width: 100%; padding: 14px 8px; border: 0; border-bottom: 1px solid var(--b-line); background: none; color: var(--b-text); font: inherit; font-size: 16px; text-align: left; cursor: pointer; }
  .phone-more-row:last-child { border-bottom: 0; }
  body.has-phone-bar .dash { min-height: 0; padding-bottom: 76px; }
  body.has-phone-bar .dash-tab, body.has-phone-bar .lc.dc, body.has-phone-bar .portal-link-button { display: none; }
  /* The dashboard: the project's name, its stage, Comments, and the drawing. */
  body.has-phone-bar .dash-phone-comments { display: inline-flex; order: 2; align-self: center; }
  body.has-phone-bar .portal-screen-logo, body.has-phone-bar .dash-top .dash-meta, body.has-phone-bar .dash-top .portal-text { display: none; }
  body.has-phone-bar .dash-top { flex-wrap: nowrap; align-items: center; }
  body.has-phone-bar .dash-top .portal-title { margin: 0; font-size: 22px; }
  body.has-phone-bar .status-track { margin: 2px 0 8px; }
  body.has-phone-bar .status-track li { flex: none; padding-top: 0; border-top: 0; color: var(--b-gold); font-size: 13px; }
  body.has-phone-bar .status-track li:not(.current) { display: none; }
  body.has-phone-bar .dash-tabs:not(:has(.dash-quote)) { display: none; }
  body.has-phone-bar .dash-viewer { height: calc(100dvh - 200px); min-height: 280px; }
  body.has-phone-bar .sheet { bottom: var(--dock-h, 66px); max-height: calc(100dvh - var(--dock-h, 66px) - 12px); }
  /* Comments: the list and a box to write in. Measure: Undo and Done. */
  .board-chip:nth-child(n+3), .board-attach { display: none; }
  .measure-clear { display: none; }
}
/* The drawings link (share.html): the project's name, Sign in, and the sheets filling the rest. */
.share-main { display: flex; flex-direction: column; height: 100dvh; padding: 0 12px calc(12px + env(safe-area-inset-bottom)); box-sizing: border-box; }
.share-bar { flex: none; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 2px; }
.share-bar h1 { margin: 0; min-width: 0; font-size: 18px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.share-host { flex: 1; min-height: 0; }
.share-note { max-width: 420px; margin: auto; padding: 24px; text-align: center; color: var(--b-text); }
.share-note h1 { margin: 0 0 8px; font-size: 22px; }
.share-gate { position: fixed; inset: 0; z-index: 400; display: grid; place-items: center; padding: 16px; background: rgba(0,0,0,0.6); }
.share-gate-card { max-width: 380px; padding: 22px; border-radius: 14px; border: 1px solid var(--b-line); background: var(--b-panel); color: var(--b-text); }
.share-gate-card h2 { margin: 0 0 8px; font-size: 20px; }
.share-gate-card p { margin: 0 0 8px; }
.share-gate-fine { font-size: 14px; opacity: 0.75; }
.share-gate-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }



.dash-page .dash-card { margin-top: 14px; }
.dash-gate { background: var(--b-panel); border: 1px solid var(--b-line); border-radius: var(--b-radius); padding: 28px 22px; display: grid; justify-items: start; gap: 6px; }
.dash-gate-art { width: 64px; height: 64px; color: var(--b-gold); }
.dash-gate-art svg { width: 100%; height: 100%; stroke-width: 1.4; }
.dash-gate-title { margin: 6px 0 0; font-size: 22px; }
.dash-gate .dash-top-actions { margin-top: 10px; }
/* the viewer inline: a framed box in the page; its Full screen button turns it into the overlay */
.svf.inline:not(.expanded) { position: relative; inset: auto; z-index: auto; height: 100%; border: 1px solid var(--b-line); border-radius: 14px; overflow: hidden; }
.svf.inline:not(.expanded) .svf-bar { padding-top: 8px; }
/* the comments widget on the dashboard */
html:not(.props-docked) .lc.dc, .lc.dc { left: 16px; bottom: 16px; z-index: 250; }
.dc-overlay { position: fixed; inset: 0; z-index: 400; display: grid; place-items: center; background: rgba(8,9,11,0.55); padding: 14px; }
.dc-panel { width: min(560px, 100%); height: min(80dvh, 700px); background: var(--b-panel); border: 1px solid var(--b-line); border-radius: 16px; padding: 12px 14px 14px; display: flex; flex-direction: column; min-height: 0; box-shadow: 0 20px 60px rgba(0,0,0,0.6); }
.dc-panel-head { display: flex; align-items: center; justify-content: space-between; padding-bottom: 8px; }
.dc-x { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 10px; border: 1px solid var(--b-line); background: var(--b-panel-2); color: var(--b-text); cursor: pointer; }
.dc-x svg { width: 18px; height: 18px; }
.dc-x:hover { border-color: var(--b-gold); }
.dc-board { flex: 1 1 auto; min-height: 0; height: auto; }
@media (max-width: 700px), (max-height: 500px) {
  html:not(.props-docked) .lc.dc, .lc.dc { left: 10px; bottom: 10px; }
  .dash-tab:not(.on) .dash-tab-name { display: none; }
  .dash-tab { padding: 0 11px; height: 44px; }
  .dash-quote { height: 44px; padding: 0 10px; gap: 6px; }
  .dash-quote-label, .dash-quote-status { display: none; }
  .dash-viewer { height: calc(100dvh - 300px); min-height: 380px; }
  /* inline on a phone: the sheet tools stay in the viewer's own bar, not a bottom dock (that is for full screen) */
  .svf.inline:not(.expanded) .svf-tools { position: static; padding: 0; background: none; border: 0; justify-content: flex-start; gap: 6px; }
  .svf.inline:not(.expanded) .svf-tools .svf-btn { flex-direction: row; width: 38px; min-width: 38px; height: 36px; border-color: var(--b-line); background: var(--b-panel-2); }
  .svf.inline:not(.expanded) .svf-tools .svf-word { display: none; }
  .svf.inline:not(.expanded) .svf-stagewrap { padding-bottom: 0; }
  .svf.inline:not(.expanded) .svf-goback { bottom: 56px; }
  .svf.inline:not(.expanded) .svf-hint { bottom: 14px; }
  .svf.inline:not(.expanded) .svf-list, .svf.inline:not(.expanded) .svf-side { bottom: 0; }
}

/* ---- Admin project page: one glass header row (logo, All projects, name, five icon tiles with the word under each, user) ---- */
.proj-bar { flex: 1 1 0; min-width: 0; display: flex; align-items: center; gap: 12px; }
.proj-bar[hidden] { display: none; }
.proj-name { min-width: 0; flex: 0 1 auto; font-size: 20px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.proj-gap { flex: 1 1 0; }
body.proj-mode .admin-switch, body.proj-mode .admin-bar .spacer { display: none; }
body.proj-mode .admin-bar { gap: 12px; flex-wrap: nowrap; background: var(--b-page); border-bottom: 0; margin-bottom: 0; padding: 6px 0 8px; }   /* the same solid bar as the walkthrough's (.site-bar) */
/* full width like the walkthrough's banner; the page content under it stays centred */
body.proj-mode .admin { max-width: none; }
body.proj-mode #adminRoot { max-width: 1180px; margin: 0 auto; }
body.proj-mode .tile-btn, body.proj-mode .user-pill { background: rgba(14,15,18,0.55); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); border-color: rgba(255,255,255,0.18); }
body.proj-mode .tile-btn:hover, body.proj-mode .user-pill:hover { border-color: var(--b-gold); }
.proj-tiles { display: flex; align-items: flex-start; gap: 4px; flex: none; pointer-events: auto; }
.proj-sep { align-self: stretch; width: 1px; margin: 4px 12px; background: rgba(255,255,255,0.2); flex: none; }
.admin-bar .proj-tile, .site-bar .proj-tile { width: 88px; min-height: 50px; padding: 3px 4px 3px; display: flex; flex-direction: column; align-items: center; justify-content: flex-start; gap: 2px; flex: none;
  border-radius: 14px; border: 1px solid transparent; background: none; color: var(--b-text); cursor: pointer; text-decoration: none; text-align: center;
  font: 600 12px/1.1 var(--b-font); text-shadow: 0 1px 3px rgba(0,0,0,0.8); transition: box-shadow 0.14s ease, border-color 0.14s ease, color 0.14s ease; }
.proj-tile .ico { display: block; line-height: 0; }
.proj-tile .ico svg { width: 24px; height: 24px; display: block; }
.admin-bar .proj-tile.on, .site-bar .proj-tile.on { color: var(--b-gold); border-color: var(--b-gold); background: rgba(201,169,97,0.14); }
@media (hover: hover) { .proj-tile:hover { border-color: var(--b-gold); box-shadow: 0 0 0 1px var(--b-gold), 0 0 12px color-mix(in srgb, var(--b-gold) 45%, transparent); } }
.proj-tile:focus-visible { outline: none; border-color: var(--b-gold); box-shadow: 0 0 0 1.5px var(--b-gold), 0 0 12px color-mix(in srgb, var(--b-gold) 45%, transparent); }
body.proj-mode .dash-viewer { height: calc(100dvh - 104px); min-height: 420px; }
.proj-area > [hidden] { display: none; }
@media (max-width: 900px) {
  .admin-bar .proj-tile { width: 64px; min-height: 50px; font-size: 12px; }
  .proj-tile .ico svg { width: 24px; height: 24px; }
  .proj-sep { margin: 6px 6px; }
}
@media (max-width: 700px), (max-height: 500px) {
  body.proj-mode .admin-bar { flex-wrap: wrap; row-gap: 6px; }
  .proj-bar { flex-wrap: wrap; gap: 8px; }
  .proj-name { font-size: 15px; flex: 1 1 0; }
  .proj-gap { display: none; }
  .proj-tiles { order: 5; flex: 1 0 100%; justify-content: center; }
  .admin-bar .proj-tile { width: 58px; font-size: 12px; }
}

/* ---- Comment bubbles as glass; the admin's hover tools (resolve / reopen, delete) ---- */
.lc .lc-msg { border: 0.5px solid rgba(255,255,255,0.16); }
.lc-item { display: flex; align-items: flex-start; gap: 4px; max-width: 100%; pointer-events: auto; }
.lc-item .lc-msg { min-width: 0; }
.lc-tools { display: flex; gap: 4px; opacity: 0; transition: opacity 0.12s ease; flex: none; }
.lc-item:hover .lc-tools, .lc-item:focus-within .lc-tools { opacity: 1; }
.lc-tool { width: 30px; height: 30px; display: grid; place-items: center; padding: 0; border-radius: 50%; cursor: pointer; color: #f2f1ee;
  background: rgba(14,15,18,0.62); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); border: 0.5px solid rgba(255,255,255,0.18); }
.lc-tool svg { width: 16px; height: 16px; display: block; }
.lc-tool:hover, .lc-tool:focus-visible { outline: none; border-color: var(--b-gold); box-shadow: 0 0 0 1.5px var(--b-gold), 0 0 10px rgba(201,169,97,0.5); }
.lc-tool.del:hover { color: #e08a76; border-color: #e08a76; box-shadow: 0 0 0 1.5px #e08a76; }
.lc-tool.ok { color: #9fbf8f; }
.lc-check { display: inline-block; vertical-align: -2px; margin-right: 4px; color: #9fbf8f; }
.lc-check svg { width: 14px; height: 14px; }

/* An iPhone zooms the whole page into a box with smaller text than this. */
@media (max-width: 700px), (max-height: 500px) {
  input:not([type="checkbox"]):not([type="radio"]):not([type="range"]), select, textarea { font-size: 16px !important; }
}

/* ---- The shared title banner (js/site-bar.js): computers only ---- */
.site-bar { display: none; }
/* A narrower window: the tiles shrink, the name gives way, then the tiles scroll, so the profile menu is always on screen. */
@media (min-width: 701px) and (min-height: 501px) and (max-width: 1460px) {
  .site-bar { gap: 8px; padding-left: 12px; padding-right: 12px; }
  .site-bar .proj-tiles { flex: 0 1 auto; min-width: 0; overflow-x: auto; scrollbar-width: none; }
  .site-bar .proj-tiles::-webkit-scrollbar { display: none; }
  .site-bar .proj-tools { flex: none; }
  .site-bar .proj-tile { width: 68px; font-size: 12px; }
  .site-bar .proj-sep { margin: 4px 4px; }
  .site-bar .proj-gap-sm { flex-basis: 8px; }
  .site-bar .user-menu, .site-bar .dash-quote { flex: none; }
}
@media (min-width: 701px) and (min-height: 501px) {
  .site-bar { display: flex; align-items: center; gap: 12px; position: fixed; top: 0; left: 0; right: 0; z-index: 45; padding: 6px 20px 8px;
    background: var(--b-page); font-family: var(--b-font); }   /* solid page colour, the same as the admin and drawings pages */
  .site-bar img { height: 22px; width: auto; filter: invert(1); display: block; }
  .site-bar .site-logo { flex: none; display: block; }
  .site-bar .proj-name { color: var(--b-text); text-decoration: none; margin: 0; }
  .site-bar .tile-btn, .site-bar .user-pill { background: rgba(14,15,18,0.55); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); border-color: rgba(255,255,255,0.18); }
  .site-bar .tile-btn:hover, .site-bar .user-pill:hover { border-color: var(--b-gold); }
  .site-bar .user-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 140px; }
  .site-bar .user-menu { position: relative; }
  /* The admin's See as client / See as admin, beside the profile pill; gold while seeing it as a client. */
  .site-bar .view-as { flex: none; display: inline-flex; align-items: center; gap: 8px; min-height: 36px; padding: 0 14px; border-radius: 999px;
    border: 1px solid var(--b-gold); background: rgba(201,169,97,0.12); color: var(--b-gold); font: 700 13px var(--b-font); text-decoration: none; white-space: nowrap; }
  .site-bar .view-as.on { background: var(--b-gold); color: #1b1710; padding-left: 6px; }
  .site-bar .view-as-note { padding: 3px 9px; border-radius: 999px; background: rgba(27,23,16,0.18); font-weight: 800; font-size: 12px; }
  @media (hover: hover) { .site-bar .view-as:hover { box-shadow: 0 0 0 1px var(--b-gold), 0 0 10px rgba(201,169,97,0.5); } }
  .site-bar .view-as:focus-visible { outline: none; box-shadow: 0 0 0 1px var(--b-gold), 0 0 10px rgba(201,169,97,0.5); }
  .site-bar { transition: opacity 0.25s ease; }
  /* the client dashboard under it: the banner already shows the logo, name and sign out */
  html.has-banner .dash { padding-top: calc(var(--top-h, 0px) + 12px); }
  html.has-banner .dash .portal-screen-logo, html.has-banner .dash .dash-top, html.has-banner .dash > .portal-link-button, html.has-banner .dash .status-track, html.has-banner .dash .dash-tabs { display: none; }
  html.has-banner .dash-viewer { height: calc(100dvh - var(--top-h, 0px) - 24px); }
}

/* ---- Drawings page: the viewer the full width of the screen (computers) ---- */
@media (min-width: 701px) and (min-height: 501px) {
  body.proj-mode.proj-wide #adminRoot { max-width: none; }
  body.proj-mode.proj-wide .admin { padding-bottom: 0; }
  body.proj-mode.proj-wide .dash-viewer { height: calc(100dvh - 76px); }
  html.has-banner .dash-body.dash-wide { max-width: none; }
  html.has-banner .dash { padding-left: 20px; padding-right: 20px; padding-bottom: 12px; }
}

/* ---- The full comments board (opened from the chat's expand button) in the chat's own glass style ---- */
.dc-overlay { background: rgba(8,9,11,0.28); }
.dc-panel { background: rgba(14,15,18,0.62); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); border: 0.5px solid rgba(255,255,255,0.16); border-radius: 18px; }
.dc-panel-head { padding: 2px 2px 10px; }
.dc-panel-head b { display: inline-flex; align-items: center; gap: 8px; font: 800 14px var(--b-font); letter-spacing: 0.03em; text-transform: uppercase; }
.dc-panel-head b::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: #4cc38a; box-shadow: 0 0 0 3px rgba(76,195,138,0.25); }
.dc-x { width: 38px; height: 38px; border-radius: 50%; background: rgba(14,15,18,0.62); border: 0.5px solid rgba(255,255,255,0.18); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.dc-x:hover { border-color: var(--b-gold); box-shadow: 0 0 0 1.5px var(--b-gold), 0 0 10px rgba(201,169,97,0.5); }
.dc-panel .board.bubbles .board-chip { background: rgba(14,15,18,0.62); border: 0.5px solid rgba(255,255,255,0.18); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); color: #f2f1ee; }
.dc-panel .board.bubbles .board-chip.on { background: rgba(201,169,97,0.2); border-color: var(--b-gold); color: var(--b-gold); }
.dc-panel .board.bubbles .board-card { background: rgba(14,15,18,0.62); border: 0.5px solid rgba(255,255,255,0.16); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.dc-panel .board.bubbles .board-card.focus { border-color: var(--b-gold); }
.dc-panel .board.bubbles .board-input { background: rgba(14,15,18,0.62); border: 0.5px solid rgba(255,255,255,0.18); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); color: #f2f1ee; }
.dc-panel .board.bubbles .board-input::placeholder { color: rgba(242,241,238,0.65); }
.dc-panel .board.bubbles .board-input:focus { border-color: var(--b-gold); }
.dc-panel .board.bubbles .board-post:hover { box-shadow: 0 0 0 1.5px var(--b-gold), 0 0 10px rgba(201,169,97,0.5); }
.dc-panel .board.bubbles .board-more, .dc-panel .board.bubbles .board-latest { background: rgba(14,15,18,0.62); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); border: 0.5px solid rgba(255,255,255,0.18); }

/* Chat folded in the sheet column: the pill sits at the very bottom and the sheet names take the room it gave up. */
.svf-list.has-foot:has(.lc.docked.folded) .svf-list-top { flex: 1 1 auto; }
.svf-list-foot:has(.lc.docked.folded) { flex: none; justify-content: flex-end; }
.lc.dc.docked.folded { margin-top: auto; }

/* ---- Banner, round two: stage chip, tools group, quote chip, Comments glow ---- */
@media (min-width: 701px) and (min-height: 501px) {
  .proj-gap-sm { flex: 0 0 22px; }
  .proj-stage { flex: none; padding: 3px 10px; border-radius: 999px; border: 1px solid rgba(201,169,97,0.55); color: var(--b-gold); font: 700 12px var(--b-font); letter-spacing: 0.03em; text-transform: uppercase; white-space: nowrap; }
  .site-bar .proj-tiles { align-items: stretch; }
  .site-bar .proj-tools { display: flex; align-items: flex-start; gap: 4px; }
  .site-bar .proj-tools[hidden], .site-bar .proj-sep[hidden] { display: none; }
  .site-bar .proj-tile { position: relative; }
  .site-bar .proj-tile[aria-pressed="false"] { color: var(--b-muted); }
  .proj-badge { position: absolute; top: 2px; right: 20px; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 999px; background: var(--b-gold); color: #1b1710; font: 800 12px/16px var(--b-font); text-align: center; text-shadow: none; }
  .site-bar .dash-quote { height: 44px; margin-right: 4px; background: rgba(14,15,18,0.55); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); border-color: rgba(255,255,255,0.18); color: var(--b-text); cursor: pointer; }
  .site-bar .dash-quote:hover { border-color: var(--b-gold); }
  .site-bar .quote-panel { min-width: 260px; padding: 14px 16px; }
  .site-bar .quote-panel p { margin: 4px 0; }
  .site-bar .quote-panel[hidden] { display: none; }
  /* the project pages in the admin use this banner on computers; the old header row is for phones */
  body.proj-mode .admin-bar { display: none; }
  html.has-banner body.proj-mode .admin { padding-top: var(--top-h, 0px); }
  body.proj-mode.proj-wide .dash-viewer { height: calc(100dvh - var(--top-h, 0px) - 12px); }
}
/* the whole chat glows gold for a moment on every Comments click */
.lc.glow { animation: lcGlow 0.95s ease-out; }
@keyframes lcGlow { 0% { filter: drop-shadow(0 0 0 rgba(201,169,97,0)); } 18% { filter: drop-shadow(0 0 9px rgba(201,169,97,0.95)) drop-shadow(0 0 3px rgba(201,169,97,0.9)); } 100% { filter: drop-shadow(0 0 0 rgba(201,169,97,0)); } }

/* Who can view a document (admin, Insert page) */
.file-list li:has(> .doc-who) { flex-wrap: wrap; }
.doc-who { flex: 1 1 100%; font-size: 13px; color: var(--b-muted); }
.doc-who summary { cursor: pointer; font-weight: 600; }

/* The drawing set dropdown in the viewer's bar (when a person may view more than one set) */
.svf-picker { max-width: min(46vw, 420px); height: 36px; padding: 0 30px 0 12px; border-radius: 10px; border: 1px solid var(--b-line); background: var(--b-panel-2); color: var(--b-text);
  font: 700 15px var(--b-font); cursor: pointer; text-overflow: ellipsis; }
.svf-picker:hover, .svf-picker:focus-visible { outline: none; border-color: var(--b-gold); box-shadow: 0 0 0 1.5px var(--b-gold), 0 0 10px rgba(201,169,97,0.4); }

/* The live links that know the marker's shape: the gold outline follows the circle and triangle (or the house-shaped tag). */
.svf .svf-link.shaped { border: 0; border-radius: 0; background: transparent; box-shadow: none; filter: none; }
.svf .svf-link.shaped:hover, .svf .svf-link.shaped:focus-visible { background: transparent; box-shadow: none; }
.svf-shape { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; transition: filter 0.12s ease; filter: drop-shadow(0 0 3px rgba(184,134,11,0.7)); }
.svf-shape polygon { fill: rgba(201,169,97,0.14); stroke: #b8860b; stroke-width: 3px; stroke-linejoin: round; vector-effect: non-scaling-stroke; transition: fill 0.12s ease; }
.svf .svf-link.shaped:hover .svf-shape, .svf .svf-link.shaped:focus-visible .svf-shape { filter: drop-shadow(0 0 4px rgba(201,169,97,0.9)); }
.svf .svf-link.shaped:hover .svf-shape polygon, .svf .svf-link.shaped:focus-visible .svf-shape polygon { fill: rgba(201,169,97,0.26); }
.svf.links-off .svf-link.shaped:not(:hover):not(:focus-visible) .svf-shape polygon { stroke: transparent; fill: transparent; }

/* Making the live links obvious: the jump badge, the label, the first-time pulse and card */
.svf-link .svf-badge { position: absolute; right: 0; top: 0; width: 16px; height: 16px; transform: translate(45%, -45%) scale(var(--inv, 1)); transform-origin: center; pointer-events: none; transition: opacity 0.15s ease; z-index: 1; }
.svf-link .svf-badge i { display: block; width: 100%; height: 100%; border-radius: 50%; box-shadow: 0 0 0 1.5px #fff, 0 1px 4px rgba(0,0,0,0.35);
  background: #b8860b url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M5.2 10.8L10.8 5.2M6.2 5.2h4.6v4.6' fill='none' stroke='white' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 100% 100% no-repeat; }
.svf.deep .svf-link .svf-badge { opacity: 0; }
.svf.links-off .svf-link .svf-badge { opacity: 0; }
.svf-label { position: absolute; z-index: 7; transform: translateX(-50%); padding: 6px 12px; border-radius: 999px; background: #1b1710; color: #f2f1ee; border: 1.5px solid #c9a961;
  font: 700 13px var(--b-font); white-space: nowrap; max-width: 90%; overflow: hidden; text-overflow: ellipsis; pointer-events: none; box-shadow: 0 6px 18px rgba(0,0,0,0.45); }
.svf-label[hidden] { display: none; }





@keyframes svfPulse { 0%, 100% { filter: drop-shadow(0 0 3px rgba(184,134,11,0.7)); } 50% { filter: drop-shadow(0 0 14px rgba(184,134,11,1)) drop-shadow(0 0 5px #b8860b); } }
@keyframes svfBadgePulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.5); } }
.svf.teach .svf-shape, .svf.teach .svf-link:not(.shaped) { animation: svfPulse 1.2s ease-in-out 5; }
.svf.teach .svf-badge i { animation: svfBadgePulse 1.2s ease-in-out 5; }
@media (prefers-reduced-motion: reduce) { .svf.teach .svf-shape, .svf.teach .svf-link:not(.shaped), .svf.teach .svf-badge i { animation: none; } }

/* ---- The guided tour (js/tour.js): a dimmed screen, a gold ring round what it points at, and a card ---- */
.tour-ov { position: fixed; inset: 0; z-index: 400; font-family: var(--b-font, inherit); }
.tour-spot { position: absolute; border-radius: 14px; box-shadow: 0 0 0 9999px rgba(0,0,0,0.66), 0 0 0 2px #c9a961, 0 0 18px rgba(201,169,97,0.55);
  transition: top 0.3s ease, left 0.3s ease, width 0.3s ease, height 0.3s ease; pointer-events: none; }
.tour-card { position: absolute; box-sizing: border-box; padding: 16px 18px; border-radius: 16px; background: rgba(14,15,18,0.96); border: 1px solid rgba(201,169,97,0.7);
  box-shadow: 0 14px 40px rgba(0,0,0,0.55); color: #f2f1ee; transition: top 0.3s ease, left 0.3s ease; }
.tour-count { font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; opacity: 0.6; margin-bottom: 6px; }
.tour-h { font-size: 16px; font-weight: 800; color: #c9a961; margin-bottom: 6px; }
.tour-p { font-size: 13.5px; line-height: 1.5; opacity: 0.92; margin-bottom: 14px; }
.tour-btns { display: flex; gap: 8px; align-items: center; }
.tour-btns button { height: 36px; padding: 0 16px; border-radius: 999px; border: 0; font: 700 13px var(--b-font, inherit); cursor: pointer; }
.tour-btns button[hidden] { display: none; }
.tour-ghost { background: rgba(255,255,255,0.08); color: #f2f1ee; }
.tour-ghost:hover { background: rgba(255,255,255,0.14); }
.tour-next { margin-left: auto; background: #c9a961; color: #1b1710; }
.tour-next:hover, .tour-next:focus-visible { outline: none; box-shadow: 0 0 0 1.5px #c9a961, 0 0 12px rgba(201,169,97,0.55); }
@media (prefers-reduced-motion: reduce) { .tour-spot, .tour-card { transition: none; } }

.finish-show { margin-left: 8px; font-size: 12px; font-weight: 600; color: var(--gold, #c9a961); text-decoration: none; border: 1px solid transparent; border-radius: 6px; padding: 1px 6px; }
.finish-show:focus-visible { border-color: var(--gold, #c9a961); box-shadow: 0 0 0 3px rgba(201, 169, 97, .25); outline: none; }
@media (hover:hover) { .finish-show:hover { border-color: var(--gold, #c9a961); box-shadow: 0 0 0 3px rgba(201, 169, 97, .25); } }

/* Clients, contractors and viewers: no Save on a picture, and nothing prints (js/portal/no-save.js) */
html.no-save img { -webkit-touch-callout: none; -webkit-user-drag: none; }
@media print { html.no-save body { display: none !important; } }
