@font-face { font-family: Inter; src: url('../vendor/inter-latin-variable.woff2') format('woff2'); font-style: normal; font-weight: 100 900; font-display: swap; }
:root {
  color-scheme: light;
  --paper: #fff;
  --off: #f7f7f3;
  --ink: #171812;
  --ink-soft: #3f4139;
  --muted: #65685f;
  --forest: #203c2c;
  --green: #315641;
  --sage: #edf2ed;
  --gold: #b49359;
  --gold-dark: #806a43;
  --line: #dfdfd7;
  --danger: #a03632;
  --header: 72px;
  --sidebar: 236px;
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 16px;
  color: var(--ink);
  background: var(--paper);
  font-synthesis: none;
  letter-spacing: 0;
}
* { box-sizing: border-box; }
body { margin: 0; line-height: 1.55; }
button, input, textarea, select { font: inherit; color: inherit; }
button, a, input, select, textarea { -webkit-tap-highlight-color: transparent; }
button, a { touch-action: manipulation; }
button { cursor: pointer; }
button:disabled { cursor: wait; opacity: .55; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
svg { width: 20px; height: 20px; flex-shrink: 0; stroke-width: 1.7; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 4px; }
h1, h2, h3, h4, p, figure { margin: 0; }
h1, h2, h3, h4 { line-height: 1.3; overflow-wrap: anywhere; }
p, dd, a, strong { overflow-wrap: anywhere; }
h1 { font-size: 28px; font-weight: 650; }
h2 { font-size: 18px; font-weight: 650; }
h3, h4 { font-size: 15px; font-weight: 650; }
p { color: var(--muted); }
small { font-size: 12px; }
.skip-link { position: fixed; top: -80px; left: 16px; z-index: 100; background: white; padding: 12px; }
.skip-link:focus { top: 8px; }
.portal-header { height: var(--header); display: flex; align-items: center; justify-content: space-between; padding: 0 20px; gap: 16px; background: var(--paper); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 30; }
.portal-brand { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.brand-mark { width: 36px; height: 40px; display: grid; place-items: center; color: var(--gold-dark); border: 1px solid var(--gold); border-radius: 4px; }
.brand-mark svg { width: 24px; height: 24px; }
.portal-brand strong { display: block; font-family: Georgia, serif; font-size: 18px; font-weight: 400; }
.portal-brand small { display: block; font-size: 11px; color: var(--muted); }
.header-tools { display: flex; align-items: center; gap: 10px; }
.header-context, .session-label, .header-tools .avatar { display: none; }
.avatar { width: 36px; height: 36px; display: grid; place-items: center; border-radius: 50%; background: var(--sage); color: var(--forest); font-size: 12px; font-weight: 600; flex-shrink: 0; }
.avatar.large { width: 56px; height: 56px; font-size: 17px; }
.icon-button { display: inline-flex; justify-content: center; align-items: center; width: 44px; height: 44px; min-width: 44px; padding: 0; background: transparent; color: var(--muted); border: 1px solid transparent; border-radius: 10px; transition: background .16s, color .16s; }
.icon-button:hover { background: var(--sage); color: var(--forest); }
.button { display: inline-flex; justify-content: center; align-items: center; gap: 8px; min-height: 44px; padding: 10px 16px; border: 1px solid transparent; border-radius: 10px; font-size: 14px; font-weight: 600; line-height: 1.4; text-align: center; transition: background .16s, border-color .16s; }
.button.primary { background: var(--forest); color: #fff; }
.button.primary:hover { background: var(--green); }
.button.secondary { background: #fff; border-color: var(--line); }
.button.secondary:hover { border-color: var(--green); background: var(--off); }
.button.plain { background: transparent; color: var(--muted); }
.text-link { display: inline-flex; align-items: center; gap: 7px; min-height: 44px; font-size: 13px; color: var(--green); font-weight: 600; }
.text-link svg { width: 16px; height: 16px; }
.text-link:hover { text-decoration: underline; text-underline-offset: 4px; }
.portal-nav { position: fixed; z-index: 45; left: 0; top: 0; bottom: 0; width: min(300px, calc(100% - 56px)); background: #fff; border-right: 1px solid var(--line); padding: 24px 16px; display: flex; flex-direction: column; transform: translateX(-100%); visibility: hidden; transition: transform .2s, visibility .2s; overflow-y: auto; }
.nav-open .portal-nav { transform: translateX(0); visibility: visible; }
.nav-open { overflow: hidden; }
.nav-backdrop { position: fixed; inset: 0; z-index: 40; border: 0; background: rgb(23 24 18 / 30%); }
.workspace-label { margin: 0 12px 22px; }
.workspace-label span { display: block; color: var(--muted); font-size: 11px; margin-bottom: 6px; }
.workspace-label strong { display: block; font-size: 13px; font-weight: 600; }
.client-picker { display: block; margin-bottom: 10px; }
.client-picker select { font-size: 13px; padding-inline: 8px; }
.workspace-label > .button { width: 100%; font-size: 12px; padding-inline: 8px; }
.nav-items { display: grid; gap: 3px; }
.nav-link { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 44px; border: 0; background: transparent; border-radius: 8px; color: var(--muted); padding: 10px 12px; font-size: 14px; text-align: left; transition: background .16s, color .16s; }
.nav-link:hover { background: var(--off); color: var(--ink); }
.nav-link.active { background: var(--sage); color: var(--forest); font-weight: 600; }
.nav-footer { border-top: 1px solid var(--line); padding-top: 12px; margin-top: auto; }
.nav-items + .nav-footer { margin-top: 32px; }
.bottom-nav { position: fixed; bottom: 0; left: 0; right: 0; padding: 6px 6px max(6px, env(safe-area-inset-bottom)); background: #fff; border-top: 1px solid var(--line); z-index: 25; display: flex; justify-content: space-around; }
.bottom-nav .nav-link { width: auto; flex: 1; flex-direction: column; gap: 3px; font-size: 11px; padding: 6px 2px; text-align: center; min-height: 50px; }
.bottom-nav .nav-link.active { background: transparent; }
.page { max-width: 1200px; margin: auto; padding: 28px 20px 104px; animation: appear .22s ease-out; }
.page-head { display: flex; flex-direction: column; gap: 20px; padding-bottom: 28px; }
.eyebrow { font-size: 11px; font-weight: 600; color: var(--gold-dark); margin-bottom: 8px; }
.page-head p:not(.eyebrow) { font-size: 14px; margin-top: 10px; max-width: 640px; }
.page-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.is-client h1 { font-family: Georgia, serif; font-weight: 400; font-size: 32px; }
.section-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; min-height: 44px; }
.section-head > :last-child:not(h2) { flex-shrink: 0; }
.section-head .text-link { font-size: 12px; }
.section-head h2 { font-size: 17px; }
.content-section { margin-top: 32px; }
.project-strip { padding: 20px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); display: flex; align-items: center; flex-wrap: wrap; gap: 12px 20px; }
.project-strip > div { flex: 1 1 100%; }
.project-strip p { font-size: 13px; margin-top: 6px; }
.badge { display: inline-flex; width: fit-content; align-items: center; gap: 5px; padding: 4px 8px; font-size: 11px; font-weight: 600; color: #53574f; background: #f0f1ee; border-radius: 5px; line-height: 1.5; white-space: normal; }
.badge.success { color: #285439; background: #eaf2eb; }
.badge.pending { color: #795619; background: #faf1df; }
.metrics { display: grid; margin: 24px 0 32px; border-block: 1px solid var(--line); }
.metrics > div { padding: 18px 0; display: grid; align-content: start; gap: 4px; }
.metrics > div + div { border-top: 1px solid var(--line); }
.metrics span, .metrics small { font-size: 12px; color: var(--muted); }
.metrics strong { font-size: 26px; font-weight: 600; font-variant-numeric: tabular-nums; }
.metrics .text-link { min-height: 32px; font-size: 12px; }
.overview-columns { display: grid; gap: 28px; }
.data-list { border-top: 1px solid var(--line); }
.activity-row { display: flex; flex-wrap: wrap; gap: 10px; padding: 18px 0; border-bottom: 1px solid var(--line); }
.activity-status { color: #94998f; display: flex; margin-top: 3px; }
.activity-status.complete { color: var(--green); }
.row-body { flex: 1; min-width: 0; }
.row-body h3 { margin-bottom: 5px; }
.row-body p, .note-row p { font-size: 14px; color: var(--muted); }
.row-meta { font-size: 11px; color: var(--muted); margin-bottom: 5px; }
.row-side { display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-basis: calc(100% - 30px); margin-left: 30px; }
.row-actions { display: flex; gap: 0; flex-shrink: 0; }
.row-actions .icon-button { width: 44px; }
.row-actions svg { width: 16px; height: 16px; }
.notes-list { display: grid; gap: 12px; }
.notes-grid { display: grid; gap: 16px; }
.note-row { padding: 18px; border: 1px solid var(--line); border-radius: 8px; background: white; }
.note-heading { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 10px; }
.note-heading .row-meta { margin: 0; }
.note-row h3 { margin-bottom: 8px; }
.note-row p { white-space: pre-line; }
.note-footer { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 12px; }
.visibility { display: inline-flex; gap: 5px; align-items: center; color: var(--green); font-size: 11px; }
.visibility.private { color: var(--muted); }
.visibility svg { width: 13px; height: 13px; }
.details-columns { display: grid; gap: 28px; }
.details-list { margin: 0; border-top: 1px solid var(--line); }
.details-list > div { display: grid; gap: 4px; padding: 14px 0; border-bottom: 1px solid var(--line); }
dt { font-size: 12px; color: var(--muted); }
dd { margin: 0; font-size: 14px; color: var(--ink-soft); }
.filter-bar { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; padding-bottom: 18px; border-bottom: 1px solid var(--line); }
.filter-bar label { flex: 1 1 140px; min-width: 0; max-width: 240px; }
.filter-bar label > span { display: block; font-size: 12px; margin-bottom: 6px; color: var(--muted); }
input, select, textarea { width: 100%; min-width: 0; border: 1px solid #c8cbc2; background: #fff; border-radius: 10px; padding: 10px 12px; min-height: 44px; font-size: 16px; line-height: 1.5; transition: border-color .16s; }
input:hover, select:hover, textarea:hover { border-color: #959e90; }
input::placeholder { color: #858980; }
textarea { resize: vertical; min-height: 100px; }
.filter-bar input, .filter-bar select { font-size: 14px; }
.list-toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 0; font-size: 12px; color: var(--muted); }
.segmented { display: inline-flex; background: var(--off); border: 1px solid var(--line); border-radius: 10px; padding: 3px; }
.segmented button { background: transparent; border: 1px solid transparent; min-height: 38px; border-radius: 7px; font-size: 12px; padding: 8px 12px; }
.segmented button[aria-pressed=true] { background: #fff; border-color: var(--line); color: var(--forest); }
.activity-group { margin-bottom: 28px; }
.activity-group > h2 { font-size: 13px; margin-bottom: 12px; color: var(--green); }
.schedule-progress { max-width: 520px; margin-bottom: 24px; }
.progress-summary { display: grid; grid-template-columns: 1fr auto; gap: 10px; font-size: 12px; color: var(--muted); }
.progress-summary strong { color: var(--forest); }
progress { display: block; grid-column: 1/-1; width: 100%; height: 5px; border: none; border-radius: 3px; overflow: hidden; background: var(--sage); accent-color: var(--green); }
progress::-webkit-progress-bar { background: var(--sage); }
progress::-webkit-progress-value { background: var(--green); border-radius: 3px; }
progress::-moz-progress-bar { background: var(--green); }
.gallery { display: grid; grid-template-columns: minmax(0, 1fr); gap: 20px; }
.photo-card { min-width: 0; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.photo-open { position: relative; display: block; width: 100%; padding: 0; border: 0; background: var(--off); aspect-ratio: 4/3; overflow: hidden; }
.photo-open img { width: 100%; height: 100%; object-fit: cover; transition: transform .25s; }
.photo-open:hover img { transform: scale(1.025); }
.photo-expand { position: absolute; bottom: 10px; right: 10px; width: 32px; height: 32px; border-radius: 6px; background: rgb(255 255 255 / 94%); display: grid; place-items: center; color: var(--forest); }
.photo-expand svg { width: 16px; height: 16px; }
.photo-caption { padding: 14px; }
.photo-caption h3 { font-size: 14px; line-height: 1.5; }
.photo-context { display: block; margin-top: 6px; font-size: 12px; color: var(--muted); }
.photo-footer { display: flex; align-items: center; justify-content: space-between; gap: 4px; }
.photo-footer:empty { display: none; }
.photo-footer:not(:empty) { margin-top: 8px; }
.client-project { position: relative; }
.project-photo { width: 100%; height: 210px; object-fit: cover; object-position: center 65%; border-radius: 8px; }
.client-project-caption { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 18px 0; border-bottom: 1px solid var(--line); }
.client-project-caption h2 { margin-top: 8px; font-size: 19px; }
.client-project-caption > span { font-size: 12px; color: var(--muted); text-align: right; }
.client-summary { display: grid; gap: 24px; padding: 24px 0; border-bottom: 1px solid var(--line); }
.client-summary h2 { font-size: 21px; font-weight: 500; max-width: 540px; }
.client-summary p:not(.eyebrow) { font-size: 13px; margin-top: 10px; }
.client-summary aside { display: grid; align-content: start; gap: 20px; }
.decision-note { display: flex; gap: 14px; border-left: 2px solid var(--gold); padding: 8px 0 8px 18px; }
.decision-note > svg { color: var(--gold-dark); margin-top: 2px; }
.decision-note h3 { font-size: 16px; }
.decision-note p { font-size: 14px; margin: 8px 0 14px; }
.decision-note .button { background: #fff; color: var(--forest); border-color: var(--line); }
.finance-list { border-top: 1px solid var(--line); }
.finance-row { display: flex; align-items: center; flex-wrap: wrap; gap: 14px; padding: 18px 0; border-bottom: 1px solid var(--line); }
.finance-icon { display: none; color: var(--green); }
.finance-row .row-body { flex-basis: calc(100% - 120px); }
.finance-row .row-body p { font-size: 12px; }
.finance-amount { display: grid; gap: 6px; justify-items: end; }
.finance-amount strong { font-size: 15px; font-variant-numeric: tabular-nums; }
.finance-row .row-actions { margin-left: auto; }
.document-list { border-top: 1px solid var(--line); }
.document-row { display: flex; align-items: center; gap: 16px; border-bottom: 1px solid var(--line); padding: 22px 0; transition: background .16s; }
.document-row:hover { background: var(--off); }
.document-row > div { flex: 1; min-width: 0; }
.document-row h2 { font-size: 16px; }
.document-row p { font-size: 13px; margin-top: 5px; }
.document-icon { width: 44px; height: 48px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 6px; color: var(--gold-dark); flex-shrink: 0; }
.document-row > svg { width: 16px; }
.proposal-document { max-width: 820px; margin: 0 auto; padding: 24px 0; border-block: 1px solid var(--line); }
.document-brand { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 32px; }
.document-brand > span:first-child { font-family: Georgia, serif; font-size: 19px; color: var(--green); }
.proposal-document > h2 { font-family: Georgia, serif; font-size: 28px; font-weight: 400; }
.proposal-meta { display: grid; gap: 20px; margin: 28px 0; padding: 22px 0; border-block: 1px solid var(--line); }
.proposal-meta dt { margin-bottom: 5px; }
.document-section-title { margin: 24px 0 16px; font-size: 16px; }
.scope-list > div { display: flex; gap: 12px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.scope-list svg { color: var(--green); }
.scope-list h4 { font-size: 14px; }
.scope-list p { margin-top: 6px; font-size: 14px; }
.optional { display: block; color: var(--muted); font-weight: 400; font-size: 11px; margin-top: 3px; }
.preserve-lines { white-space: pre-line; font-size: 14px; }
.proposal-total { border-top: 1px solid var(--gold); margin-top: 28px; padding-top: 22px; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; }
.proposal-total span { font-size: 14px; }
.proposal-total strong { color: var(--forest); font-size: 28px; }
.export-intro { display: flex; gap: 16px; align-items: center; border-block: 1px solid var(--line); padding: 24px 0; }
.export-intro h2 { font-size: 19px; }
.export-intro p { font-size: 13px; margin: 6px 0; }
.export-preview > h3 { margin: 28px 0 16px; }
.preview-row { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; padding: 14px 0; border-bottom: 1px solid var(--line); font-size: 13px; }
.preview-row strong { flex: 1; min-width: 140px; font-weight: 500; }
.preview-row > span:first-child { color: var(--muted); }
.preview-entry { border-bottom: 1px solid var(--line); padding: 16px 0; }
.preview-entry small { color: var(--muted); }
.preview-entry h4 { margin: 6px 0; }
.preview-entry p { font-size: 14px; white-space: pre-line; }
.contact-profile { display: flex; align-items: center; gap: 16px; padding: 22px 0; border-block: 1px solid var(--line); }
.contact-profile p { font-size: 13px; margin-top: 5px; }
.contact-details { max-width: 560px; padding: 24px 0; display: flex; align-items: flex-start; flex-direction: column; gap: 18px; }
.contact-details p { font-size: 14px; }
.is-logged-out .portal-nav, .is-logged-out .bottom-nav, .is-logged-out .header-context { display: none; }
.is-logged-out .portal-header { position: relative; justify-content: center; border: 0; height: 96px; }
.login-wrap { display: grid; align-items: start; justify-content: center; padding: 24px 24px 40px; min-height: calc(100svh - 96px); }
.login-page { width: min(100%, 380px); }
.login-identity { display: none; }
.login-content h1 { font-family: Georgia, serif; font-weight: 400; font-size: 36px; line-height: 1.2; }
.login-content > p:not(.eyebrow) { margin-top: 16px; font-size: 14px; }
.login-content form { margin-top: 30px; }
.field { display: flex; flex-direction: column; gap: 7px; min-width: 0; margin-bottom: 18px; }
.field > label, .field > span { font-size: 13px; font-weight: 500; }
.field small { color: var(--muted); font-size: 11px; }
.password-field { position: relative; }
.password-field input { padding-right: 52px; }
.password-field .icon-button { position: absolute; right: 2px; top: 2px; }
.login-content form > .button { width: 100%; min-height: 48px; justify-content: space-between; }
.form-error { color: var(--danger); font-size: 13px; }
.form-error:not(:empty) { margin: 12px 0; }
.login-help { display: flex; justify-content: center; margin-top: 18px; font-weight: 400; font-size: 12px; }
.login-foot { margin-top: 40px; border-top: 1px solid var(--line); padding-top: 22px; text-align: center; font-size: 11px; }
.empty-state { padding: 40px 20px; text-align: center; grid-column: 1/-1; }
.empty-state > svg { color: var(--gold-dark); margin-bottom: 16px; width: 28px; height: 28px; }
.empty-state h3 { font-size: 16px; }
.empty-state p { font-size: 13px; margin-top: 8px; }
.loading-state { padding: 40px; }
.toast { position: fixed; left: 20px; right: 20px; bottom: 86px; z-index: 90; margin: auto; width: fit-content; max-width: calc(100% - 40px); border: 1px solid var(--line); border-radius: 8px; padding: 12px 18px; background: white; box-shadow: 0 6px 24px rgb(23 24 18 / 12%); font-size: 14px; opacity: 0; transform: translateY(8px); pointer-events: none; transition: opacity .2s, transform .2s; }
.toast.visible { opacity: 1; transform: none; }
dialog { border: 1px solid var(--line); padding: 0; color: var(--ink); border-radius: 12px; }
dialog::backdrop { background: rgb(18 26 21 / 55%); }
body:has(dialog[open]) { overflow: hidden; }
.portal-dialog { width: min(620px, calc(100% - 24px)); max-height: calc(100dvh - 32px); }
.dialog-shell { display: flex; flex-direction: column; max-height: calc(100dvh - 34px); }
.dialog-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.dialog-head h2 { font-size: 18px; }
.dialog-body { padding: 22px 20px 8px; overflow-y: auto; min-height: 0; }
.dialog-actions { display: flex; justify-content: flex-end; gap: 8px; padding: 16px 20px; border-top: 1px solid var(--line); background: white; }
.dialog-shell > .form-error:not(:empty) { padding: 0 20px; margin-bottom: 14px; }
.form-grid { display: grid; gap: 0 18px; }
.checkbox-field { display: flex; align-items: center; gap: 10px; min-height: 44px; font-size: 13px; margin-bottom: 12px; }
.checkbox-field input { width: 18px; height: 18px; min-height: 18px; accent-color: var(--forest); }
.scope-editor { padding: 0; border: 0; margin-top: 20px; }
.scope-editor legend { font-size: 16px; font-weight: 600; margin-bottom: 10px; }
.scope-editor > div { padding: 16px 0; border-top: 1px solid var(--line); }
.workspace-actions, .page-actions, .scope-editor-title, .scope-edit-head, .scope-price-fields { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.workspace-actions .button { min-height: 36px; padding: 8px 11px; font-size: 12px; }
.revision-history { margin-top: 26px; border-top: 1px solid var(--line); }
.revision-row { display: flex; align-items: center; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.revision-row > div { flex: 1; min-width: 0; }
.revision-row h4 { font-size: 14px; }
.revision-row p { margin-top: 4px; font-size: 12px; color: var(--muted); }
.scope-editor-title { justify-content: space-between; margin-bottom: 10px; }
.scope-editor-title legend { margin: 0; }
.scope-edit-row { padding: 18px 0; border-top: 1px solid var(--line); }
.scope-edit-head { justify-content: space-between; }
.scope-edit-head .checkbox-field { margin: 0; }
.scope-price-fields { align-items: flex-start; }
.scope-price-fields .field { flex: 1 1 150px; }
.image-preview { min-height: 42px; margin-top: 10px; display: grid; gap: 8px; align-items: start; color: var(--muted); font-size: 12px; }
.image-preview:empty { display: none; }
.image-preview img { display: block; width: min(100%, 320px); max-height: 190px; object-fit: contain; object-position: left center; border: 1px solid var(--line); border-radius: 6px; background: var(--off); }
.photo-dialog { width: min(1100px, calc(100% - 20px)); background: #161b17; color: #fff; border-color: #3d443f; padding: 12px; max-height: calc(100dvh - 24px); }
.photo-dialog::backdrop { background: rgb(0 0 0 / 88%); }
.photo-toolbar { display: flex; align-items: center; justify-content: space-between; font-size: 13px; padding-left: 10px; }
.photo-dialog .icon-button { color: #fff; }
.photo-dialog .icon-button:hover { background: #303a32; }
.photo-dialog figure img { height: min(64dvh, 740px); width: 100%; object-fit: contain; }
.photo-dialog figcaption { padding: 14px 10px; text-align: center; font-size: 13px; color: #e0e5df; }
.photo-navigation { display: flex; justify-content: center; gap: 12px; }
@keyframes appear { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
@media (min-width: 560px) {
  .page { padding-inline: 28px; }
  .metrics { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .metrics > div { padding: 22px 16px; }
  .metrics > div:first-child { padding-left: 0; }
  .metrics > div + div { border-top: 0; border-left: 1px solid var(--line); }
  .metrics strong { font-size: 23px; }
  .gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .proposal-meta { grid-template-columns: 1fr 1fr; }
  .form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .field.full, .form-grid .checkbox-field { grid-column: 1/-1; }
  .project-photo { height: 260px; }
  .project-strip > div { flex: 1; }
  .finance-row { flex-wrap: nowrap; }
  .finance-icon { display: inline-flex; }
  .finance-row .row-body { flex-basis: auto; }
  .finance-amount { min-width: 110px; }
  .login-wrap { align-items: center; padding-bottom: 100px; }
}
@media (min-width: 960px) {
  .portal-header { padding: 0 28px; }
  .portal-brand { width: calc(var(--sidebar) - 28px); }
  .header-context { display: flex; align-items: center; gap: 10px; flex: 1; font-size: 12px; color: var(--muted); min-width: 0; }
  .header-context svg { width: 16px; height: 16px; }
  .session-label, .header-tools .avatar { display: grid; }
  .session-label strong { font-size: 12px; font-weight: 500; max-width: 200px; }
  .session-label small { font-size: 11px; color: var(--muted); }
  .mobile-menu, .bottom-nav, .nav-backdrop { display: none; }
  .portal-nav { width: var(--sidebar); top: var(--header); transform: none; visibility: visible; z-index: 20; padding: 28px 14px 20px; }
  .nav-open { overflow: auto; }
  .nav-items + .nav-footer { margin-top: auto; padding-top: 14px; }
  main { margin-left: var(--sidebar); }
  .page { padding: 36px 36px 64px; }
  .page-head { flex-direction: row; justify-content: space-between; align-items: center; gap: 24px; padding-bottom: 28px; }
  .page-actions { flex-shrink: 0; max-width: 48%; }
  .metrics strong { font-size: 27px; }
  .notes-grid { grid-template-columns: 1fr 1fr; }
  .details-columns { grid-template-columns: .85fr 1.3fr; gap: 44px; }
  .client-summary { grid-template-columns: 1fr 240px; gap: 40px; }
  .project-photo { height: 270px; }
  .proposal-document { padding: 32px 16px; }
  .toast { bottom: 24px; }
  .is-client h1 { font-size: 36px; }
  .is-logged-out main { margin-left: 0; }
  .is-logged-out .portal-header .portal-brand { width: auto; }
}
@media (min-width: 1200px) {
  .page { padding-inline: 44px; }
  .overview-columns { grid-template-columns: 1.4fr 1fr; gap: 32px; }
  .gallery { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .notes-list { max-width: 860px; }
  .activity-row { flex-wrap: nowrap; gap: 12px; }
  .row-side { flex-basis: auto; margin-left: 0; flex-direction: column; justify-content: flex-start; align-items: flex-end; }
  .is-client .row-side { justify-content: center; }
}
@media (max-width: 359px) {
  .portal-header { padding-inline: 16px; }
  .page { padding-inline: 16px; }
  .portal-brand strong { font-size: 16px; }
  h1 { font-size: 25px; }
  .is-client h1, .login-content h1 { font-size: 30px; }
  .button { padding-inline: 12px; font-size: 13px; }
  .section-head { flex-wrap: wrap; gap: 4px; }
  .page-actions .button { width: 100%; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; } }
@media print { .portal-header, .portal-nav, .bottom-nav, .page-head, .toast, .skip-link { display: none !important; } main { margin: 0; } .page { padding: 0; } .proposal-document { border: 0; } .scope-list > div { break-inside: avoid; } @page { size: A4; margin: 15mm; } }
