@font-face{font-family:"DM Sans";src:url("/dm-sans.woff2") format("woff2");font-weight:400 800;font-display:swap}
@font-face{font-family:"Bricolage Grotesque";src:url("/bricolage.woff2") format("woff2");font-weight:400 800;font-display:swap}

:root {
  color-scheme: light;
  --ink: #101622;
  --navy: #0e1420;
  --blue: #2f5eff;
  --blue-dark: #2149df;
  --paper: #f5f7fc;
  --white: #fff;
  --line: #e1e6f0;
  --muted: #53627a;
  --light-text: #b7c1d5;
  --display: "Bricolage Grotesque", "Segoe UI", sans-serif;
  --body: "DM Sans", "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 14px/1.5 var(--body); }
h1,h2,h3,h4,p { margin: 0; }
h1,h2,h3 { font-family: var(--display); line-height: 1.08; }
a { color: inherit; text-decoration: none; }
button,input,select,textarea { font: inherit; }
button { cursor: pointer; }
button[disabled] { cursor: default; opacity: .55; }
button, a, input, select, textarea, summary { -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }
img { display: block; max-width: 100%; }
svg { flex: none; }
::selection { background: #dce4ff; color: var(--ink); }
.skip-link { position: fixed; left: 12px; top: 12px; z-index: 20; padding: 8px 15px; background: white; border-radius: 6px; transform: translateY(-150%); }
.skip-link:focus { transform: none; }
.loading { padding: 32px; color: var(--muted); }
.login-card { max-width: 410px; margin: 9vh auto 0; }
.login-card img { margin-bottom: 21px; }
.login-card h1 { font-size: 28px; margin-bottom: 6px; }
.login-card > .button { width: 100%; }

.layout { min-height: 100vh; display: grid; grid-template-columns: 224px minmax(0,1fr); }
.sidebar { align-self: start; position: sticky; top: 0; height: 100dvh; min-height: 450px; display: flex; flex-direction: column; padding: 26px 15px 17px; color: white; background: var(--navy); }
.brand { display: flex; gap: 10px; align-items: center; padding-left: 12px; font: 800 29px/.95 var(--display); letter-spacing: -1.3px; }
.brand > img { width: 21px; height: 25px; object-fit: contain; }
.brand > span span { color: #7190ff; }
.workspace { display: flex; align-items: center; gap: 10px; padding: 10px; margin-top: 34px; border: 1px solid #333e52; background: #1a2232; border-radius: 10px; }
.workspace-mark { display: grid; place-items: center; flex: 0 0 33px; height: 33px; background: #fff; border-radius: 7px; }
.workspace-mark img { width: 16px; height: 19px; object-fit: contain; }
.workspace strong,.profile strong { display: block; font-size: 13px; font-weight: 730; }
.workspace small,.profile small { display: block; color: var(--light-text); font-size: 11px; }
.nav-caption { margin: 31px 11px 9px; color: #abb7cf; font-size: 10px; font-weight: 800; letter-spacing: .14em; }
.sidebar nav { display: grid; gap: 4px; }
.sidebar nav button { display: flex; gap: 11px; align-items: center; width: 100%; min-height: 43px; padding: 7px 11px; border: 1px solid transparent; border-radius: 8px; color: #c8d0e1; background: transparent; text-align: left; font-weight: 650; }
.sidebar nav button:hover { background: #212b3e; color: white; }
.sidebar nav button[aria-current] { color: #fff; border-color: #3a4d7f; background: #273657; box-shadow: inset 3px 0 #7190ff; }
.sidebar nav button[aria-current] svg { color: #a5b7ff; }
.sidebar-bottom { margin-top: auto; }
.local-status { display: flex; align-items: center; gap: 8px; margin: 0 11px 17px; color: #bbc6d9; font-size: 11px; }
.local-status i { width: 7px; height: 7px; border-radius: 50%; background: #63e4aa; box-shadow: 0 0 0 3px #245049; }
.profile { display: flex; align-items: center; gap: 10px; padding: 14px 7px 0; border-top: 1px solid #303a4f; }
.profile > span { display: grid; place-items: center; width: 33px; height: 33px; border-radius: 50%; background: #dce5ff; color: #173797; font-size: 11px; font-weight: 800; }
.sign-out { margin: 12px 7px 0; border: 0; background: none; padding: 5px; color: var(--light-text); font-size: 12px; }
.sign-out:hover { color: white; text-decoration: underline; }
.topbar { min-height: 61px; padding: 0 clamp(19px,3vw,42px); display: flex; align-items: center; justify-content: space-between; gap: 16px; background: var(--white); border-bottom: 1px solid var(--line); }
.crumb,.top-right { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 13px; }
.crumb strong { color: var(--ink); font-weight: 700; }
.mobile-menu { display: none !important; }
.content { margin-inline: auto; padding: 31px clamp(19px,3vw,42px) 48px; max-width: 1680px; }
.page-heading,.section-heading { display: flex; justify-content: space-between; align-items: center; gap: 15px; }
.page-heading { margin-bottom: 23px; }
.page-heading h1 { font-size: clamp(32px,4vw,46px); font-weight: 800; letter-spacing: -.052em; }
.page-heading p,.section-heading p { color: var(--muted); margin-top: 7px; }
.section-heading h2 { font-size: 25px; letter-spacing: -.035em; font-weight: 780; }
.section-heading h3 { font-size: 22px; letter-spacing: -.03em; }

.button,.icon-button { display: inline-flex; justify-content: center; align-items: center; gap: 8px; min-height: 41px; border: 1px solid transparent; border-radius: 8px; padding: 0 14px; white-space: nowrap; font-weight: 750; line-height: 1.2; transition: background .15s, border-color .15s; }
.button.primary { background: var(--blue-dark); color: white; }
.button.primary:hover { background: #1739c8; }
.button.secondary,.icon-button { background: white; color: var(--ink); border-color: var(--line); }
.button.secondary:hover,.icon-button:hover { border-color: #a5b7f2; background: #f3f6ff; }
.icon-button { padding: 0; width: 34px; min-height: 34px; flex-shrink: 0; }
.text-button { padding: 3px 0; border: 0; background: none; color: #2249d3; font-weight: 740; text-align: left; }
.text-button:hover { text-decoration: underline; }

.hero { position: relative; min-height: 240px; display: grid; grid-template-columns: 1fr .93fr; overflow: hidden; isolation: isolate; align-items: center; border-radius: 16px; background: #244ce7; color: white; }
.hero-text { position: relative; z-index: 2; padding: 23px 0 24px 28px; }
.hero-label { display: inline-flex; align-items: center; gap: 7px; color: #eef2ff; font-size: 10px; font-weight: 800; letter-spacing: .12em; }
.hero h2 { font-size: clamp(39px,5vw,66px); font-weight: 790; line-height: .88; margin: 10px 0 13px; letter-spacing: -.065em; }
.hero p { max-width: 337px; font-size: 13px; color: #eff3ff; line-height: 1.45; }
.hero-button { display: inline-flex; gap: 9px; align-items: center; min-height: 32px; margin-top: 15px; border: 1px solid #a7bbff; border-radius: 6px; padding: 0 10px; background: #ffffff12; color: white; font-weight: 750; font-size: 11px; }
.hero-button:hover { background: #ffffff30; }
.hero-art { position: absolute; inset: 0 0 0 36%; overflow: hidden; background: radial-gradient(ellipse at 68% 50%, #476eff 0%, #2a52ef 52%, #244ce7 75%); }
.hero-grid { position: absolute; inset: 0; background-image: linear-gradient(#cbd7ff29 1px, transparent 1px),linear-gradient(90deg,#cbd7ff29 1px, transparent 1px); background-size: 29px 29px; mask-image: linear-gradient(90deg,transparent 3%,#000 47%); }
.hero-art img { position: absolute; height: 73%; width: auto; max-width: 48%; object-fit: contain; top: 13%; left: 64%; transform: translateX(-50%); filter: drop-shadow(12px 16px 0 #142fb346); }
.orbit { position: absolute; border: 1px solid #c5d4ff70; width: clamp(220px,37vw,520px); height: 68%; top: 50%; left: 64%; border-radius: 50%; transform: translate(-50%,-50%) rotate(-20deg); }
.orbit.two { height: 92%; width: clamp(290px,44vw,650px); opacity: .6; }
.orbit.three { height: 121%; width: clamp(320px,52vw,750px); opacity: .4; }

.metrics { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 13px; margin: 17px 0 31px; }
.metric { display: flex; gap: 11px; align-items: center; min-height: 86px; padding: 12px; background: white; border: 1px solid var(--line); border-radius: 12px; }
.metric-icon,.stage-icon,.empty-icon { display: inline-grid; place-items: center; width: 39px; height: 39px; flex: none; border-radius: 9px; background: #e9edf5; color: #485871; }
.metric strong { display: block; font: 790 29px/.98 var(--display); letter-spacing: -.055em; font-variant-numeric: tabular-nums; }
.metric div > span { display: block; color: var(--muted); font-size: 11px; font-weight: 680; margin-top: 5px; }
.stage-icon { width: 33px; height: 33px; border-radius: 8px; }
.blue { background: #e8eeff; color: #254ace; }
.slate { background: #e9edf5; color: #465773; }
.violet { background: #f1eafd; color: #6336a6; }
.indigo { background: #e8eafd; color: #3d46a2; }
.cyan { background: #dff4fa; color: #066676; }
.amber { background: #fff1d7; color: #875012; }
.green { background: #e1f6eb; color: #186344; }

.board-section,.activity { margin-top: 14px; }
.board-tools { display: flex; gap: 8px; margin: 15px 0 12px; }
.search { display: flex; align-items: center; gap: 7px; max-width: 310px; flex: 1 1 230px; padding: 0 10px; background: white; color: var(--muted); border: 1px solid var(--line); border-radius: 8px; }
.search input { width: 100%; border: 0; padding: 7px 0; background: transparent; }
.search input:focus-visible { outline: none; }
.search:focus-within { outline: 2px solid var(--blue); outline-offset: 2px; }
.board-tools > select { flex: 0 1 170px; min-width: 0; }
.board-tools input,.board-tools select { min-height: 36px; font-size: 12px; }
.scroll-controls { display: flex; gap: 6px; }
.board { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(222px,calc((100% - 36px)/4)); gap: 12px; overflow-x: auto; padding: 2px 2px 12px; scrollbar-width: thin; scrollbar-color: #9caecc #e7ebf5; scroll-snap-type: x proximity; }
.lane { scroll-snap-align: start; border: 1px solid var(--line); border-radius: 10px; min-height: 180px; background: #edf1f8; transition: background .12s; }
.lane.drag-over { background: #dce7ff; outline: 2px dashed #345cf4; outline-offset: -3px; }
.lane-head { display: flex; gap: 8px; align-items: center; padding: 11px 9px; border-bottom: 1px solid var(--line); }
.lane-head div { min-width: 0; }
.lane-head div > span { display: block; color: var(--muted); font-size: 9px; font-weight: 800; letter-spacing: .07em; margin-bottom: 2px; }
.lane-head h3 { font-size: 15px; font-weight: 780; }
.lane-count { margin-left: auto; display: grid; place-items: center; min-width: 24px; height: 23px; border: 1px solid var(--line); border-radius: 6px; background: white; color: #3c4e6b; font-size: 11px; font-weight: 800; }
.lane-body { display: grid; align-content: start; padding: 8px; gap: 7px; }
.lane-empty { display: grid; place-items: center; min-height: 76px; border: 1px dashed #c8d2e6; border-radius: 7px; color: var(--muted); font-size: 11px; text-align: center; padding: 7px; }
.project-card { display: block; width: 100%; padding: 10px; border: 1px solid #dce3f0; background: white; border-radius: 7px; text-align: left; color: var(--ink); }
.project-card[draggable=true] { cursor: grab; }
.project-card:hover { border-color: #9caff1; box-shadow: 0 2px 6px #182a4612; }
.project-card > strong { display: block; margin: 6px 0 4px; font-size: 14px; font-weight: 780; overflow-wrap: anywhere; }
.card-client,.card-meta { color: var(--muted); font-size: 10px; display: flex; align-items: center; gap: 6px; }
.client-letter { background: #e6eeff; color: #2046b6; font-weight: 800; border-radius: 5px; padding: 3px 5px; }
.card-meta { justify-content: space-between; flex-wrap: wrap; }
.card-meta > span { display: inline-flex; gap: 4px; align-items: center; white-space: nowrap; }
.project-progress { display: block; overflow: hidden; height: 3px; margin-top: 9px; background: #e7edf9; border-radius: 5px; }
.project-progress i { display: block; height: 100%; border-radius: inherit; background: var(--blue); }
.activity { margin-top: 24px; }
.activity .section-heading { margin-bottom: 12px; }
.activity-list,.empty,.collection-card { background: white; border: 1px solid var(--line); border-radius: 12px; }
.activity-list > div { padding: 11px 14px; display: flex; gap: 9px; align-items: center; border-bottom: 1px solid var(--line); }
.activity-list > div:last-child { border: 0; }
.activity-list small { display: block; color: var(--muted); }
.activity-list .grow { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.activity-list time { margin-left: auto; color: var(--muted); font-size: 12px; }
.empty { display: grid; place-items: center; text-align: center; padding: 21px; gap: 4px; }
.empty strong { font-size: 14px; }
.empty p { color: var(--muted); font-size: 12px; }
.empty-icon { margin-bottom: 6px; background: #edf1fb; color: #526892; }
.collection { display: grid; gap: 14px; }
.collection-card { padding: 19px; }
.collection-card .section-heading { margin-bottom: 11px; }
.collection-card h2 { font-size: 21px; }
.templates .phase { padding: 3px 9px; margin: 0; }
.templates summary div { flex: 1; }
.templates summary h2 { margin: 2px 0 3px; }
.templates summary p { margin: 0; }
.templates pre { font: 13px/1.7 var(--body); white-space: pre-wrap; overflow-wrap: anywhere; color: var(--muted); }
.plan-tools { display: flex; gap: 7px; flex-wrap: wrap; margin: 13px 0 12px; }
.contract-workspace { display: grid; gap: 13px; }
.contract-workspace .collection-card { margin: 0; }
.package-row { display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; align-items: center; gap: 12px; padding: 11px 0; border-top: 1px solid var(--line); }
.package-row > .button:last-child { grid-column: 4; }
.package-row small, .contract-facts small { color: var(--muted); display: block; }
.package-row strong { overflow-wrap: anywhere; }
.package-price { font-size: 12px; font-weight: 750; color: var(--muted); }
.package-row .button { min-height: 33px; font-size: 12px; }
.contract-facts { display: grid; grid-template-columns: 1.4fr .6fr 1fr; gap: 6px; margin: 13px 0; }
.contract-facts > div { border-radius: 8px; padding: 8px; background: #eef3ff; overflow-wrap: anywhere; }
.contract-edit { margin-top: 12px; }
.contract-edit h4, .contract-versions h4 { margin: 12px 0 7px; }
.contract-profile .phase-body { padding-top: 6px; }
.contract-originals { border: 0; padding: 0; margin: 0 0 13px; }
.contract-originals legend { font-weight: 760; margin-bottom: 5px; }
.contract-autofill { border: 1px solid var(--line); border-radius: 8px; padding: 0 12px 12px; margin-bottom: 12px; background: #f5f7fc; }
.contract-autofill p { white-space: pre-wrap; overflow-wrap: anywhere; }
.contract-versions { margin-top: 19px; }
.commercial-editor .phase-body { padding: 9px 11px 11px; }
.commercial-fields textarea { width: 100%; }
.commercial-fields .field:has(textarea) { grid-column: 1 / -1; }
.quote-summary { margin: 0 0 8px; border-radius: 7px; background: #e8eeff; padding: 8px 11px; color: #203eaa; font-weight: 750; }
.legal-sources summary { padding: 0; }
.legal-sources summary .helper { margin-bottom: 0; }
.legal-sources li a { color: #2249d3; }
.legal-sources li a:hover { text-decoration: underline; }
.contract-print { width: min(860px, calc(100% - 24px)); margin: 21px auto; }
.print-toolbar { display: flex; justify-content: space-between; margin-bottom: 14px; gap: 8px; }
.contract-paper { background: white; padding: clamp(19px, 5vw, 52px); border: 1px solid var(--line); border-radius: 12px; }
.print-logo { width: 115px; margin-bottom: 23px; }
.contract-paper h1 { margin: 0 0 20px; font-size: clamp(23px, 4vw, 36px); letter-spacing: -.035em; }
.contract-paper section { margin: 0 0 15px; }
.contract-paper section h2 { font-size: 17px; margin: 0 0 5px; }
.contract-paper section p { white-space: pre-wrap; overflow-wrap: anywhere; }
.signature-block { margin-top: 30px; break-inside: avoid; }
.signature-block div { display: grid; grid-template-columns: 1fr 1fr; gap: 38px 20px; margin-top: 40px; }
.signature-block div p { border-top: 1px solid currentColor; padding-top: 4px; overflow-wrap: anywhere; }

dialog { padding: 0; border: 1px solid var(--line); width: min(560px,calc(100% - 24px)); max-height: calc(100dvh - 40px); border-radius: 15px; color: var(--ink); box-shadow: 0 24px 90px #08163159; }
dialog::backdrop { background: #101a34a3; }
dialog.wide { width: min(785px,calc(100% - 24px)); }
.dialog-top { display: flex; gap: 12px; justify-content: space-between; align-items: start; padding: 20px 22px 12px; }
.dialog-top h2 { font-weight: 800; font-size: clamp(24px,4vw,34px); letter-spacing: -.04em; overflow-wrap: anywhere; }
.eyebrow { font-size: 10px; font-weight: 800; letter-spacing: .1em; color: #254bc5; margin-bottom: 7px; text-transform: uppercase; }
.dialog-body,.detail-content { padding: 0 22px 20px; }
.helper,.phase-body > p { color: var(--muted); margin-bottom: 11px; }
.field-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 0 12px; }
.field { display: grid; gap: 5px; margin-bottom: 12px; min-width: 0; }
.field > span { font-size: 12px; font-weight: 760; }
.field b { color: #be3445; }
input, select, textarea { min-height: 39px; border: 1px solid #cdd7e9; border-radius: 7px; padding: 7px 9px; background: white; color: var(--ink); }
input[type=checkbox] { min-height: initial; width: 17px; height: 17px; accent-color: var(--blue-dark); flex: none; }
textarea { resize: vertical; }
.field-hint,.field small { color: var(--muted); font-size: 11px; display: block; margin: -6px 0 12px; }
.field small { margin: 0; }
.form-actions { display: flex; justify-content: flex-end; gap: 8px; flex-wrap: wrap; margin-top: 14px; }
.form-actions > button:only-child { margin-left: auto; }
.inline-error:not(:empty) { margin: 9px 0 4px; padding: 8px 10px; border: 1px solid #f4c3c7; color: #8c2030; background: #fff0f1; border-radius: 7px; font-weight: 680; }
.detail-heading { display: flex; justify-content: space-between; align-items: center; padding: 0 22px 12px; color: var(--muted); gap: 8px; }
.detail-tabs { display: flex; gap: 13px; padding: 0 22px; overflow-x: auto; border-bottom: 1px solid var(--line); }
.detail-tabs button { white-space: nowrap; background: none; border: 0; border-bottom: 2px solid transparent; padding: 9px 1px; color: var(--muted); font-size: 12px; font-weight: 720; }
.detail-tabs button[aria-current] { color: #2149dc; border-color: var(--blue); }
.detail-content { padding-top: 14px; }
.detail-content > h3 { margin: 14px 0 7px; }
.project-status { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; font-size: 11px; color: var(--muted); }
.project-status > span { display: inline-flex; gap: 5px; align-items: center; }
.badge { display: inline-flex; flex: none; align-items: center; gap: 5px; padding: 4px 7px; border-radius: 6px; font-weight: 760; font-size: 10px; line-height: 1.2; }
.badge > span { border-radius: 50%; width: 5px; height: 5px; background: currentColor; }
.progress-steps { display: grid; grid-template-columns: repeat(7,1fr); gap: 5px; margin: 10px 0 14px; }
.progress-steps span { display: block; background: #e3e9f5; height: 5px; border-radius: 9px; }
.progress-steps .current { background: var(--blue-dark); }
.progress-steps .past { background: #4da77e; }
.scope { color: var(--muted); white-space: pre-wrap; margin: 8px 0 12px; overflow-wrap: anywhere; }
.phase { margin: 0 0 7px; border: 1px solid var(--line); border-radius: 8px; background: #fcfdff; }
.phase summary { padding: 8px; list-style: none; cursor: pointer; display: flex; align-items: center; gap: 8px; }
.phase summary::-webkit-details-marker { display: none; }
.phase summary::after { content: "+"; color: var(--muted); font-weight: 800; margin-left: auto; width: 13px; }
.phase[open] summary::after { content: "−"; }
.phase summary strong { font-size: 13px; overflow-wrap: anywhere; }
.phase-count { margin-left: auto; color: var(--muted); font-size: 11px; white-space: nowrap; }
.phase-count + * { margin-left: 0; }
.phase summary:has(.phase-count)::after { margin-left: 2px; }
.phase-body { padding: 0 11px 11px; }
.check-row { display: flex; gap: 7px; align-items: start; border-top: 1px solid var(--line); padding: 7px 0; cursor: pointer; font-size: 13px; }
.check-row span { overflow-wrap: anywhere; }
.check-row input:disabled + span { color: var(--muted); }
.check-row small { color: var(--muted); margin-left: 4px; font-size: 10px; }
.phase-body .sequence-note { font-size: 11px; margin: 5px 0 0; }
.notes-form { margin-top: 12px; }
.stage-actions { padding-top: 10px; border-top: 1px solid var(--line); }
.history ul { padding: 0 11px 0 28px; }
.history time { color: var(--muted); margin-right: 5px; }
.record-list { margin-top: 12px; }
.link-row { display: flex; align-items: center; gap: 8px; padding: 8px 0; border-bottom: 1px solid var(--line); min-width: 0; }
.link-row .grow { flex: 1 1 auto; min-width: 0; overflow-wrap: anywhere; }
.link-row strong { display: block; font-size: 12px; }
.link-row small { display: block; color: var(--muted); font-size: 11px; white-space: pre-line; }
a.link-row:hover strong { color: #2149d3; text-decoration: underline; }
.responses { margin-top: 9px; }
.responses h4 { margin-top: 12px; }
.responses dl { margin: 6px 0; }
.responses dt { margin: 5px 0; color: var(--muted); font-size: 11px; font-weight: 750; }
.responses dd { margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; }
.file-list { margin-top: 8px; }
#notice { position: fixed; z-index: 12; bottom: 18px; right: 18px; max-width: min(520px,calc(100% - 36px)); padding: 10px 14px; background: var(--ink); border: 1px solid #35496f; color: #fff; border-radius: 8px; box-shadow: 0 7px 20px #14224c39; opacity: 0; pointer-events: none; transform: translateY(7px); transition: opacity .15s, transform .15s; }
#notice.visible { opacity: 1; transform: none; }
.dialog-notice { position: sticky; z-index: 1; bottom: 0; padding: 9px 14px; background: #e8eeff; color: #203eaa; border-top: 1px solid #c2d0f9; font-size: 12px; font-weight: 750; }

.public-layout { min-height: 100dvh; }
.public-header { height: 66px; border-bottom: 1px solid var(--line); background: white; display: flex; justify-content: space-between; align-items: center; padding: 0 max(19px,calc((100% - 960px)/2)); gap: 12px; }
.public-header img { width: 125px; }
.public-header span { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); }
.public-content { max-width: 705px; margin: 0 auto; padding: 29px 17px 10px; }
.public-wide { max-width: 995px; }
.public-intro h1,.public-success h1 { font-size: clamp(32px,5vw,51px); font-weight: 800; letter-spacing: -.053em; overflow-wrap: anywhere; }
.public-intro p,.public-success p { color: var(--muted); margin: 8px 0; }
.public-card,.public-success { margin-top: 13px; padding: 20px; border: 1px solid var(--line); border-radius: 12px; background: white; }
.public-card h2 { font-size: 22px; letter-spacing: -.03em; margin-bottom: 5px; }
.public-card .field { margin-top: 13px; }
.public-card .field-hint { margin-top: -7px; }
.public-success .stage-icon { width: 52px; height: 52px; margin-bottom: 13px; }
.wizard-progress { display: grid; gap: 5px; margin-top: 17px; color: var(--muted); font-weight: 740; font-size: 12px; }
.wizard-progress div { height: 5px; border-radius: 6px; background: #dce5f8; overflow: hidden; }
.wizard-progress i { display: block; height: 100%; background: var(--blue); }
.privacy-note { display: flex; align-items: center; gap: 7px; margin-top: 12px; padding: 8px 9px; border-radius: 7px; background: #edf2ff; color: #31457b; font-size: 11px; }
.public-footer { color: var(--muted); font-size: 11px; text-align: center; padding: 14px; }
.portal-steps { display: grid; list-style: none; margin: 14px 0 0; padding: 0; grid-template-columns: repeat(7,minmax(0,1fr)); gap: 5px; }
.portal-steps li { border-top: 2px solid #dce4f4; padding: 9px 5px 4px; }
.portal-steps li > span { display: inline-grid; place-items: center; width: 23px; height: 23px; background: #edf1f8; color: #53627a; font-size: 11px; font-weight: 800; border-radius: 50%; margin-bottom: 5px; }
.portal-steps li strong,.portal-steps li small { display: block; font-size: 11px; }
.portal-steps li small { color: var(--muted); margin-top: 4px; }
.portal-steps .current { border-color: var(--blue); }
.portal-steps .current > span { background: var(--blue-dark); color: white; }
.portal-steps .past { border-color: #52ae85; }
.portal-steps .past > span { background: #d9f5e7; color: #176143; }
.portal-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 10px; }

@media (max-width: 1050px) {
  .layout { grid-template-columns: 194px minmax(0,1fr); }
  .metric { padding: 9px; gap: 7px; }
  .metric-icon { width: 32px; height: 32px; }
}

@media (max-width: 800px) {
  .layout { display: block; }
  .sidebar { display: none; }
  .sidebar.is-open { display: flex; position: fixed; z-index: 5; top: 55px; left: 0; height: calc(100dvh - 55px); min-height: 0; width: min(260px,85vw); overflow-y: auto; box-shadow: 0 15px 36px #11172445; }
  .sidebar.is-open .sidebar-bottom { padding-top: 20px; }
  .topbar { min-height: 55px; position: sticky; top: 0; z-index: 4; }
  .mobile-menu { display: inline-flex !important; }
  .content { padding-top: 20px; }
}

@media (max-width: 540px) {
  .top-right { display: none; }
  .page-heading { align-items: start; margin-bottom: 16px; }
  .page-heading p,.section-heading p { font-size: 12px; }
  .page-heading .button { padding: 0 8px; font-size: 11px; min-height: 36px; }
  .page-heading .button svg { width: 15px; }
  .hero { grid-template-columns: 1.1fr .5fr; min-height: 205px; }
  .hero-text { padding: 17px 0 19px 16px; }
  .hero h2 { font-size: 38px; }
  .hero p { font-size: 11px; }
  .hero-art { left: 40%; }
  .hero-art img { max-width: 42%; }
  .metrics { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 7px; margin: 10px 0 24px; }
  .metric { min-height: 64px; }
  .metric strong { font-size: 25px; }
  .section-heading h2 { font-size: 21px; }
  .board-tools > select { flex-basis: 139px; }
  .board { grid-auto-columns: minmax(220px,75%); }
  .field-grid,.portal-grid { grid-template-columns: 1fr; }
  .dialog-top { padding: 15px 12px 9px; }
  .dialog-body,.detail-content { padding-inline: 12px; }
  .detail-heading,.detail-tabs { padding-inline: 12px; }
  .link-row { gap: 5px; }
  .link-row .icon-button { width: 30px; min-height: 30px; }
  .public-card,.public-success { padding: 14px; }
  .portal-steps { grid-template-columns: 1fr; }
  .portal-steps li { display: flex; gap: 8px; border-top: 0; border-left: 2px solid #dce4f4; padding: 3px 5px 6px; }
  .package-row { gap: 7px; grid-template-columns: auto minmax(0, 1fr) auto; }
  .package-row > .button:last-child { grid-column: 3; }
  .package-price { grid-column: 2; grid-row: 2; }
  .package-row > .button { grid-row: 1; }
}

@page { size: A4; margin: 17mm 18mm; }
@media print {
  body:has(.contract-print) { background: #fff; color: #000; font: 10pt/1.45 "DM Sans", sans-serif; }
  .contract-print { width: auto; margin: 0; }
  .contract-print .print-toolbar, body:has(.contract-print) .skip-link { display: none; }
  .contract-paper { border: none; padding: 0; border-radius: 0; }
  .contract-paper h1 { font-size: 19pt; }
  .contract-paper section h2 { font-size: 12pt; break-after: avoid; }
  .contract-paper p { orphans: 3; widows: 3; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: 0s !important; }
}
