:root {
  --ink: #101012;
  --panel: #171719;
  --panel-2: #202024;
  --paper: #f3eee5;
  --muted: #b9b0a5;
  --line: rgba(243, 238, 229, 0.14);
  --red: #c44b2f;
  --red-2: #e06849;
  --green: #6fbf8f;
  --blue: #80a8c8;
  --shadow: 0 20px 60px rgba(0, 0, 0, 0.28);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--ink);
  color: var(--paper);
}

a {
  color: inherit;
}

button,
input {
  font: inherit;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 72px;
  padding: 14px clamp(18px, 4vw, 48px);
  background: rgba(16, 16, 18, 0.92);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
}

.brand,
.login-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.brand strong,
.login-brand strong {
  display: block;
  line-height: 1.1;
  font-size: 15px;
  letter-spacing: 0;
}

.brand small,
.login-brand small {
  display: block;
  color: var(--muted);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-top: 3px;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid rgba(196, 75, 47, 0.6);
  border-radius: 8px;
  background: #0c0c0d;
  box-shadow: inset 0 0 18px rgba(196, 75, 47, 0.18);
}

.brand-mark span {
  color: var(--red-2);
  font-weight: 800;
  font-size: 22px;
}

.brand-mark.large {
  width: 52px;
  height: 52px;
}

.brand-mark.large span {
  font-size: 30px;
}

.icon-button,
button,
.download-actions a,
.secondary-button {
  border: 1px solid rgba(243, 238, 229, 0.18);
  border-radius: 8px;
  color: var(--paper);
  background: var(--red);
  padding: 11px 15px;
  text-decoration: none;
  cursor: pointer;
}

.icon-button,
.secondary-button {
  background: transparent;
}

.login-screen {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(320px, 540px) minmax(280px, 1fr);
  gap: clamp(24px, 5vw, 72px);
  align-items: stretch;
  padding: clamp(20px, 5vw, 64px);
}

.login-panel,
.login-aside {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.login-panel {
  padding: clamp(24px, 5vw, 48px);
  align-self: center;
}

.login-aside {
  display: flex;
  min-height: 560px;
  justify-content: flex-end;
  flex-direction: column;
  padding: clamp(26px, 5vw, 54px);
  background:
    linear-gradient(rgba(16, 16, 18, 0.7), rgba(16, 16, 18, 0.92)),
    repeating-linear-gradient(0deg, rgba(243, 238, 229, 0.04) 0 1px, transparent 1px 32px),
    repeating-linear-gradient(90deg, rgba(243, 238, 229, 0.04) 0 1px, transparent 1px 32px),
    var(--panel-2);
}

.login-aside h2 {
  max-width: 760px;
  margin: 0;
  font-size: clamp(34px, 6vw, 78px);
  line-height: 0.98;
  letter-spacing: 0;
}

.login-aside p:last-child {
  max-width: 660px;
  color: var(--muted);
  line-height: 1.6;
}

.login-panel h1 {
  margin: 42px 0 12px;
  font-size: clamp(32px, 5vw, 54px);
  letter-spacing: 0;
  line-height: 1;
}

.lede {
  color: var(--muted);
  line-height: 1.55;
}

.login-form {
  display: grid;
  gap: 16px;
  margin-top: 30px;
}

label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
}

input[type="text"],
input[type="password"],
input[name="username"],
input[name="password"],
input[type="file"] {
  width: 100%;
  border: 1px solid rgba(243, 238, 229, 0.16);
  border-radius: 8px;
  background: #0f0f11;
  color: var(--paper);
  padding: 13px 14px;
}

textarea,
select {
  width: 100%;
  border: 1px solid rgba(243, 238, 229, 0.16);
  border-radius: 8px;
  background: #0f0f11;
  color: var(--paper);
  padding: 13px 14px;
}

textarea {
  resize: vertical;
  min-height: 132px;
}

.form-error {
  border: 1px solid rgba(224, 104, 73, 0.42);
  background: rgba(196, 75, 47, 0.12);
  color: #ffd5ca;
  padding: 11px 12px;
  border-radius: 8px;
}

.assurance-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-top: 26px;
}

.assurance-grid span {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
  color: var(--muted);
  font-size: 12px;
}

.workspace {
  width: min(1480px, calc(100vw - 36px));
  margin: 0 auto;
  padding: 32px 0 56px;
}

.workspace-hero,
.job-header,
.upload-band,
.table-section,
.warning-panel,
.review-grid article,
.review-workspace {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}

.workspace-hero,
.job-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: end;
  padding: clamp(24px, 5vw, 46px);
}

.workspace-hero h1,
.job-header h1 {
  max-width: 960px;
  margin: 0 0 14px;
  font-size: clamp(36px, 6vw, 76px);
  line-height: 0.98;
  letter-spacing: 0;
}

.job-header h1 {
  overflow-wrap: anywhere;
}

.workspace-hero p,
.job-header p,
.section-title p,
.upload-band p {
  color: var(--muted);
  line-height: 1.55;
}

.eyebrow {
  color: var(--red-2);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 12px;
  font-weight: 700;
}

.metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin: 16px 0;
}

.metrics article {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-2);
  padding: 18px;
}

.metrics span {
  display: block;
  font-size: 28px;
  font-weight: 800;
}

.metrics small {
  color: var(--muted);
}

.upload-band {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 460px);
  gap: 28px;
  align-items: center;
  padding: 24px;
}

.upload-band h2,
.table-section h2,
.warning-panel h2,
.review-grid h2 {
  margin: 0 0 8px;
  font-size: 22px;
}

.upload-form {
  display: grid;
  gap: 12px;
}

.table-section,
.warning-panel {
  margin-top: 16px;
  overflow: hidden;
}

.section-title {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  padding: 22px 24px 12px;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  padding: 14px 16px;
  border-top: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

th {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

td {
  color: #e5ded3;
  font-size: 14px;
}

td a {
  color: var(--paper);
  font-weight: 700;
}

.status {
  display: inline-block;
  border-radius: 999px;
  padding: 5px 9px;
  font-size: 12px;
  background: rgba(128, 168, 200, 0.16);
  color: #bdd7eb;
}

.status.ready {
  background: rgba(111, 191, 143, 0.18);
  color: #b8e7c9;
}

.status.failed {
  background: rgba(196, 75, 47, 0.2);
  color: #ffc9bd;
}

.empty {
  color: var(--muted);
}

.download-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.package-actions {
  margin-top: 18px;
}

.package-actions a {
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(243, 238, 229, 0.18);
  border-radius: 8px;
  background: var(--red);
  color: var(--paper);
  padding: 11px 15px;
  text-decoration: none;
}

.professional-panel {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: 22px;
  margin-top: 18px;
  border: 1px solid rgba(111, 191, 143, 0.32);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(111, 191, 143, 0.13), rgba(20, 20, 22, 0.92)),
    var(--panel);
  padding: 24px;
}

.professional-panel h2,
.professional-panel h3 {
  margin: 0;
}

.professional-panel p {
  color: var(--muted);
  line-height: 1.55;
}

.layer-code-strip {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 12px 0 16px;
}

.layer-code-strip code {
  border: 1px solid rgba(243, 238, 229, 0.14);
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.2);
  padding: 6px 8px;
  font-size: 12px;
}

.qa-checks {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.qa-checks li {
  border: 1px solid rgba(243, 238, 229, 0.12);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.16);
  padding: 12px 14px;
}

.qa-checks li span {
  display: inline-block;
  margin-left: 8px;
  border-radius: 999px;
  padding: 2px 7px;
  background: rgba(243, 238, 229, 0.12);
  color: #e5ded3;
  font-size: 11px;
  text-transform: uppercase;
}

.qa-checks li.pass span {
  background: rgba(111, 191, 143, 0.2);
  color: #b8e7c9;
}

.qa-checks li.warn span {
  background: rgba(226, 183, 93, 0.2);
  color: #f3d38c;
}

.qa-checks li.fail span {
  background: rgba(196, 75, 47, 0.22);
  color: #ffc9bd;
}

.qa-checks p {
  margin: 6px 0 0;
  font-size: 13px;
}

.back-link {
  color: var(--muted);
  text-decoration: none;
  font-size: 13px;
}

.review-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 16px;
}

.audit-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 16px;
  margin-top: 16px;
}

.audit-grid article {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  padding: 22px 24px;
}

.audit-grid p {
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.6;
}

.layer-list {
  display: grid;
  gap: 10px;
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
  color: #e5ded3;
}

.layer-chip {
  display: inline-block;
  min-width: 190px;
  margin-right: 8px;
  border: 1px solid rgba(243, 238, 229, 0.14);
  border-radius: 6px;
  padding: 5px 8px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px;
}

.layer-chip.opening,
.layer-chip.meta {
  color: #b8e7c9;
}

.layer-chip.meta {
  color: #f2c6b9;
  background: rgba(196, 75, 47, 0.14);
}

.layer-chip.trace {
  color: #f4eee3;
  background: rgba(243, 238, 229, 0.12);
}

.layer-chip.room {
  color: #bcd8ee;
  background: rgba(128, 168, 200, 0.14);
}

.layer-chip.wall {
  color: #f4eee3;
  background: rgba(111, 191, 143, 0.16);
}

.layer-chip.label {
  color: #c3e4d0;
  background: rgba(111, 191, 143, 0.14);
}

.layer-chip.exterior {
  color: #f1d1c7;
  background: rgba(196, 75, 47, 0.14);
}

.review-workspace {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 380px);
  gap: 18px;
  margin-top: 16px;
  padding: 18px;
}

.cad-preview {
  min-width: 0;
}

.source-plan-card {
  margin-bottom: 14px;
  border: 1px solid rgba(243, 238, 229, 0.12);
  border-radius: 8px;
  background: #f7f7f4;
  overflow: hidden;
}

.source-plan-card h3 {
  margin: 0;
  padding: 10px 12px;
  color: #191918;
  font-size: 13px;
  letter-spacing: 0;
}

.source-plan-card img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 520px;
  object-fit: contain;
  border-top: 1px solid rgba(16, 16, 18, 0.12);
}

.section-title.compact {
  padding: 4px 2px 14px;
}

.calibration-panel {
  display: grid;
  align-content: start;
  gap: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #111113;
  padding: 18px;
}

.calibration-panel h2 {
  margin: 0;
}

.model-svg {
  display: block;
  width: 100%;
  height: auto;
  min-height: 300px;
  border: 1px solid rgba(243, 238, 229, 0.12);
  border-radius: 8px;
  background: #0d1012;
}

.conversion-proof,
.exterior-proof {
  display: grid;
  gap: 14px;
  margin-bottom: 14px;
}

.output-contract {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.output-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #111113;
  color: #e5ded3;
  padding: 9px 11px;
  font-size: 12px;
}

.output-chip strong {
  color: var(--paper);
}

.proof-stage {
  border: 1px solid rgba(243, 238, 229, 0.12);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(128, 168, 200, 0.12), rgba(13, 16, 18, 0.2)),
    #0d1012;
  overflow: hidden;
}

.proof-stage svg {
  display: block;
  width: 100%;
  height: clamp(320px, 38vw, 430px);
}

.proof-shadow {
  fill: rgba(0, 0, 0, 0.32);
}

.proof-front {
  fill: url("#proofWall");
  stroke: rgba(243, 238, 229, 0.64);
  stroke-width: 2;
}

.proof-side {
  fill: #788a91;
  stroke: rgba(243, 238, 229, 0.44);
  stroke-width: 2;
}

.proof-roof-main,
.proof-roof-side {
  fill: url("#proofRoof");
  stroke: rgba(243, 238, 229, 0.72);
  stroke-width: 2;
}

.proof-roof-side {
  fill: #5c3c33;
}

.proof-roof-lines {
  fill: none;
  stroke: rgba(243, 238, 229, 0.42);
  stroke-width: 2;
}

.proof-roof-badge text,
.proof-label,
.proof-small {
  fill: var(--paper);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

.proof-roof-badge rect {
  fill: rgba(16, 16, 18, 0.72);
  stroke: rgba(243, 238, 229, 0.2);
}

.proof-roof-badge text {
  font-size: 15px;
  font-weight: 800;
}

.proof-label {
  font-size: 20px;
  font-weight: 800;
}

.proof-small {
  font-size: 13px;
  opacity: 0.76;
}

.proof-window {
  fill: #17242d;
  stroke: #d5edf4;
  stroke-width: 2;
}

.proof-door {
  fill: #5a372f;
  stroke: #f3eee5;
  stroke-width: 2;
}

.proof3d-shell {
  display: grid;
  gap: 10px;
  --proof-rot-x: -18deg;
  --proof-rot-y: -34deg;
  --proof-pan-x: 0px;
  --proof-pan-y: 0px;
  --proof-scale: 1;
}

.proof3d-toolbar {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.proof3d-toolbar button {
  padding: 8px 10px;
  background: #111113;
  font-size: 12px;
}

.proof3d-toolbar span {
  color: var(--muted);
  font-size: 12px;
}

.proof3d-viewport {
  position: relative;
  min-height: clamp(360px, 48vw, 560px);
  border: 1px solid rgba(243, 238, 229, 0.12);
  border-radius: 8px;
  background:
    radial-gradient(circle at 50% 18%, rgba(128, 168, 200, 0.22), transparent 34%),
    linear-gradient(180deg, rgba(128, 168, 200, 0.1), rgba(13, 16, 18, 0.2)),
    #0d1012;
  overflow: hidden;
  cursor: grab;
  touch-action: none;
  user-select: none;
}

.proof3d-viewport:active {
  cursor: grabbing;
}

.proof3d-scene {
  position: absolute;
  inset: 0;
  perspective: 1050px;
  perspective-origin: 50% 38%;
}

.proof3d-ground {
  position: absolute;
  left: 50%;
  top: 70%;
  width: min(78%, 760px);
  height: 180px;
  border: 1px solid rgba(243, 238, 229, 0.08);
  border-radius: 50%;
  background:
    repeating-linear-gradient(0deg, rgba(243, 238, 229, 0.05) 0 1px, transparent 1px 24px),
    repeating-linear-gradient(90deg, rgba(243, 238, 229, 0.04) 0 1px, transparent 1px 24px),
    rgba(0, 0, 0, 0.24);
  transform: translate(-50%, -50%) rotateX(76deg);
  filter: blur(0.1px);
}

.proof3d-building {
  position: absolute;
  left: 50%;
  top: 52%;
  width: 360px;
  height: 220px;
  transform-style: preserve-3d;
  transform:
    translate3d(calc(-50% + var(--proof-pan-x)), calc(-50% + var(--proof-pan-y)), 0)
    scale(var(--proof-scale))
    rotateX(var(--proof-rot-x))
    rotateY(var(--proof-rot-y));
  transition: transform 160ms ease;
}

.proof3d-viewport.is-dragging .proof3d-building {
  transition: none;
}

.proof3d-face,
.proof3d-roof {
  position: absolute;
  transform-style: preserve-3d;
  backface-visibility: visible;
  border: 1px solid rgba(243, 238, 229, 0.28);
  box-shadow: inset 0 0 28px rgba(0, 0, 0, 0.18);
}

.proof3d-face {
  height: 220px;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.11), transparent 32%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(0, 0, 0, 0.16));
}

.proof3d-front,
.proof3d-back {
  width: 360px;
}

.proof3d-right,
.proof3d-left {
  width: 260px;
}

.proof3d-front {
  transform: translateZ(130px);
}

.proof3d-back {
  transform: rotateY(180deg) translateZ(130px);
}

.proof3d-right {
  transform-origin: left center;
  transform: translateX(360px) rotateY(90deg);
}

.proof3d-left {
  transform-origin: right center;
  transform: translateX(-260px) rotateY(-90deg);
}

.proof3d-roof {
  width: 388px;
  height: 142px;
  left: -14px;
  top: -84px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.14), transparent 26%),
    repeating-linear-gradient(90deg, rgba(243, 238, 229, 0.13) 0 1px, transparent 1px 38px),
    #654033;
  border-color: rgba(243, 238, 229, 0.42);
}

.proof3d-roof-main {
  transform-origin: bottom center;
  transform: translateZ(34px) rotateX(56deg);
}

.proof3d-roof-rear {
  transform-origin: bottom center;
  transform: translateZ(-126px) rotateY(180deg) rotateX(56deg);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.08), transparent 28%),
    repeating-linear-gradient(90deg, rgba(243, 238, 229, 0.09) 0 1px, transparent 1px 38px),
    #52372f;
}

.material-stucco {
  background-color: #cfc5b2;
}

.material-siding {
  background:
    repeating-linear-gradient(0deg, rgba(16, 16, 18, 0.1) 0 2px, transparent 2px 15px),
    #93a9b4;
}

.face-title,
.material-band,
.roof-title,
.roof-facet-marker {
  position: absolute;
  border: 1px solid rgba(16, 16, 18, 0.18);
  border-radius: 6px;
  background: rgba(16, 16, 18, 0.74);
  color: var(--paper);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0;
  padding: 4px 6px;
}

.face-title {
  left: 10px;
  top: 9px;
}

.material-band {
  left: 10px;
  bottom: 10px;
  text-transform: uppercase;
}

.material-band.stone {
  background: rgba(88, 91, 78, 0.82);
}

.material-band.brick {
  background: rgba(125, 61, 43, 0.84);
}

.material-band.siding {
  background: rgba(58, 86, 101, 0.84);
}

.material-band.stucco {
  background: rgba(92, 83, 70, 0.84);
}

.feature-marker {
  position: absolute;
  left: var(--x);
  top: var(--y);
  width: max(16px, var(--w));
  height: max(20px, var(--h));
  transform: translate(-50%, -50%);
  border: 2px solid rgba(243, 238, 229, 0.84);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.22);
}

.feature-marker.window {
  border-color: #d5edf4;
  background:
    linear-gradient(90deg, transparent 47%, rgba(213, 237, 244, 0.55) 47% 53%, transparent 53%),
    linear-gradient(0deg, transparent 47%, rgba(213, 237, 244, 0.45) 47% 53%, transparent 53%),
    #162633;
}

.feature-marker.door {
  border-color: #f3eee5;
  border-bottom-width: 4px;
  background:
    radial-gradient(circle at 78% 52%, #f3eee5 0 2px, transparent 3px),
    #62362d;
}

.roof-title {
  left: 10px;
  top: 10px;
}

.roof-facet-marker {
  left: var(--x);
  top: var(--y);
  transform: translate(-50%, -50%);
  background: rgba(243, 238, 229, 0.9);
  color: #221614;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 9px;
}

.roof-pitch-strip,
.feature-ledger {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.roof-pitch-chip,
.feature-ledger span {
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #111113;
  color: #e5ded3;
  padding: 7px 10px;
  font-size: 12px;
}

.feature-ledger strong {
  color: var(--paper);
}

.proof-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.proof-stats div {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #111113;
  padding: 12px;
}

.proof-stats span {
  display: block;
  color: var(--muted);
  font-size: 12px;
}

.proof-stats strong {
  display: block;
  margin-top: 5px;
  color: var(--paper);
  font-size: 17px;
}

.material-strip {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.material-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 7px 10px;
  color: #e5ded3;
  background: #111113;
  font-size: 12px;
}

.material-chip i {
  display: block;
  width: 10px;
  height: 10px;
  border-radius: 3px;
  background: var(--muted);
}

.material-chip.siding i {
  background: #80a8c8;
}

.material-chip.stucco i {
  background: #d6ccb8;
}

.material-chip.stone i {
  background: #9aa091;
}

.material-chip.brick i {
  background: #c44b2f;
}

.proof-note {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
  font-size: 13px;
}

.grid-bg {
  fill: #0d1012;
}

.trace-bg {
  fill: #f8f8f4;
}

.cad-bg {
  fill: #f8f8f4;
}

.cad-lines line {
  stroke: #101012;
  stroke-width: 2.2;
  stroke-linecap: square;
  vector-effect: non-scaling-stroke;
}

.cad-title {
  fill: #c44b2f;
  font-size: 18px;
  font-weight: 800;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

.trace-lines line {
  stroke: #101012;
  stroke-width: 2.4;
  stroke-linecap: square;
  vector-effect: non-scaling-stroke;
}

.trace-note {
  fill: #c44b2f;
  font-size: 28px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

.grid-lines {
  fill: url("#grid");
}

.model-svg pattern path {
  stroke: rgba(128, 168, 200, 0.14);
  stroke-width: 1;
}

.room-blocks rect {
  fill: rgba(128, 168, 200, 0.09);
  stroke: #80a8c8;
  stroke-width: 2;
}

.room-blocks text {
  fill: var(--paper);
  font-size: 13px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

.empty-preview {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 24px;
  color: var(--muted);
}

.review-grid article,
.warning-panel {
  padding: 22px 24px;
}

dl {
  display: grid;
  grid-template-columns: 130px 1fr;
  gap: 10px 16px;
  margin: 16px 0 0;
}

dt {
  color: var(--muted);
}

dd {
  margin: 0;
}

.check-list,
.warning-panel ul {
  margin: 14px 0 0;
  padding-left: 18px;
  color: #e5ded3;
  line-height: 1.6;
}

.split-tables {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr);
  gap: 18px;
  margin-top: 22px;
}

@media (max-width: 880px) {
  .login-screen,
  .workspace-hero,
  .job-header,
  .upload-band,
  .review-grid,
  .audit-grid,
  .professional-panel,
  .review-workspace,
  .split-tables {
    grid-template-columns: 1fr;
  }

  .login-aside {
    min-height: 360px;
  }

  .metrics {
    grid-template-columns: repeat(2, 1fr);
  }

  .proof-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .proof3d-shell {
    --proof-scale: 0.86;
  }

  .section-title {
    display: block;
  }

  table {
    min-width: 760px;
  }

  .table-section {
    overflow-x: auto;
  }
}

@media (max-width: 520px) {
  .topbar {
    min-height: 64px;
  }

  .brand small,
  .login-brand small {
    letter-spacing: 0.08em;
  }

  .metrics,
  .assurance-grid,
  .proof-stats {
    grid-template-columns: 1fr;
  }

  .proof3d-shell {
    --proof-scale: 0.72;
  }

  .proof3d-viewport {
    min-height: 380px;
  }

  .workspace {
    width: min(100vw - 24px, 1480px);
  }
}
