:root {
  --paper: #f6f4ed;
  --paper-light: #fbfaf6;
  --panel: #fffefa;
  --white: #ffffff;
  --ink: #183d3d;
  --ink-soft: #49645c;
  --muted: #738071;
  --line: #dfe3d6;
  --line-strong: #becab6;
  --sage: #e9eee2;
  --sage-deep: #d4dfc9;
  --accent: #b86a48;
  --accent-soft: #f5e7da;
  --warning: #946a2e;
  --warning-soft: #fbf0dc;
  --danger: #a1493d;
  --danger-soft: #fbebe5;
  --success: #527445;
  --shadow: 0 8px 35px rgb(26 48 35 / 6%);
  --font: "Inter", "Avenir Next", "Segoe UI", -apple-system, BlinkMacSystemFont, sans-serif;
  --serif: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Georgia, serif;
  --header-height: 76px;
}

* { box-sizing: border-box; }
html { color-scheme: light; scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--font); font-size: 14px; line-height: 1.55; -webkit-font-smoothing: antialiased; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
button, a, input, select, textarea, [tabindex] { -webkit-tap-highlight-color: transparent; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, [tabindex]:focus-visible { outline: 3px solid #bf8d64; outline-offset: 3px; }
button:disabled, button[aria-disabled="true"] { cursor: not-allowed; opacity: .45; }
input, textarea { min-width: 0; }
input[type="checkbox"], input[type="radio"] { accent-color: var(--ink); width: 17px; height: 17px; flex: 0 0 17px; margin: 2px 0 0; }
a { color: var(--ink); text-underline-offset: 3px; }
svg, canvas, img { display: block; }
svg, img { max-width: 100%; }
h1, h2, h3, h4, p { margin: 0; }
ul { padding-left: 20px; }
[hidden] { display: none !important; }
::selection { background: #d8e2cd; color: var(--ink); }
* { scrollbar-width: thin; scrollbar-color: #c3cdb9 transparent; }
::-webkit-scrollbar { width: 7px; height: 7px; }
::-webkit-scrollbar-thumb { background: #c3cdb9; border-radius: 10px; }
.icon { width: 18px; height: 18px; flex: 0 0 18px; }
.muted { color: var(--muted); }
.eyebrow { display: block; color: var(--muted); font-size: 12px; font-weight: 620; letter-spacing: .115em; line-height: 1.5; text-transform: uppercase; }
.section-label { margin: 20px 0 10px; font-size: 12px; font-weight: 650; letter-spacing: .065em; text-transform: uppercase; }
.divider { height: 1px; width: 100%; background: var(--line); border: 0; margin: 19px 0; }
.preserve-lines { white-space: pre-wrap; overflow-wrap: anywhere; }
.text-button { display: inline; padding: 0; border: 0; border-bottom: 1px solid #b7c4a9; background: transparent; font-size: inherit; line-height: inherit; color: #526f44; }
.text-button:hover { color: var(--ink); border-color: var(--ink); }

/* The studio's quiet, persistent navigation. */
.studio-header { position: relative; z-index: 40; min-height: var(--header-height); display: grid; grid-template-columns: minmax(220px, 1fr) auto minmax(220px, 1fr); align-items: center; gap: 20px; padding: 13px 28px; background: var(--paper-light); border-bottom: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 11px; width: fit-content; min-width: 0; color: var(--ink); text-decoration: none; }
.brand-mark { width: 38px; height: 42px; flex: 0 0 38px; display: grid; place-items: center; }
.brand-mark svg { width: 36px; height: 40px; }
.brand-name { display: block; font-size: 13px; font-weight: 700; line-height: 1.35; letter-spacing: .12em; }
.brand-subtitle { display: block; font-size: 12px; color: var(--muted); line-height: 1.35; margin-top: 3px; letter-spacing: .09em; }
.studio-nav { display: flex; align-items: center; gap: 3px; padding: 4px; background: #eeefe6; border-radius: 9px; }
.studio-nav button { min-height: 35px; padding: 7px 14px; border: 0; border-radius: 6px; background: transparent; font-size: 13px; font-weight: 550; white-space: nowrap; color: #7a8674; transition: background .15s, color .15s; }
.studio-nav button:hover { color: var(--ink); background: #e3e8d9; }
.studio-nav button.active { color: var(--ink); background: #fffefa; box-shadow: 0 1px 5px rgb(29 58 35 / 8%); }
.header-actions { display: flex; justify-content: flex-end; align-items: center; gap: 8px; }
.save-indicator { display: inline-flex; gap: 6px; align-items: center; white-space: nowrap; font-size: 12px; color: #7b8a70; }
.save-indicator::before { content: ""; width: 5px; height: 5px; flex: 0 0 5px; border-radius: 50%; background: #89a176; }
.header-actions .btn { white-space: nowrap; }
.nav-count { display: inline-flex; align-items: center; justify-content: center; min-width: 19px; height: 19px; margin-left: 4px; padding-inline: 3px; border-radius: 4px; background: #dde5d3; color: #60784d; font-size: 12px; }

/* Controls are deliberately generous enough to read and use. */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 40px; padding: 10px 15px; border: 1px solid var(--line); border-radius: 7px; background: var(--white); color: var(--ink); font-size: 13px; font-weight: 560; line-height: 1.3; text-decoration: none; transition: background .16s, border-color .16s, box-shadow .16s, transform .16s; }
.btn:hover { background: #f0f4e8; border-color: #a9bc99; }
.btn.primary { background: var(--ink); border-color: var(--ink); color: #fffdf7; }
.btn.primary:hover { background: #2d554a; border-color: #2d554a; }
.btn.secondary { background: var(--paper-light); border-color: #d2d9c8; }
.btn.ghost { background: transparent; border-color: transparent; color: #5f7754; }
.btn.ghost:hover { background: var(--sage); }
.btn.small { min-height: 34px; padding: 7px 11px; font-size: 12px; }
.btn.icon { width: 36px; min-height: 36px; height: 36px; padding: 8px; flex: 0 0 36px; }
.btn.icon .icon { width: 17px; height: 17px; flex-basis: 17px; }
.btn.danger { color: var(--danger); }
.btn.danger:hover { background: var(--danger-soft); border-color: #ddb2a5; }
.btn.full-width { width: 100%; }
.badge { display: inline-flex; align-items: center; gap: 5px; width: fit-content; padding: 4px 8px; border-radius: 4px; background: var(--sage); color: #60774f; font-size: 12px; font-weight: 550; line-height: 1.35; }
.badge.accent { color: #996344; background: var(--accent-soft); }
.badge.warning { color: var(--warning); background: var(--warning-soft); }
.badge.success { color: var(--success); background: #e9f2df; }
.help-note { margin: 14px 0; padding: 12px 14px; border-left: 2px solid #becea9; background: #f0f4e9; color: #74866a; font-size: 12px; line-height: 1.65; }
.help-note > .icon { display: inline-block; width: 14px; height: 14px; vertical-align: -2px; margin-right: 4px; }
.empty-state { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; min-height: 180px; padding: 30px 24px; border: 1px dashed #cad5bd; border-radius: 12px; color: #829574; font-size: 13px; line-height: 1.7; text-align: center; }
.empty-state .icon { width: 30px; height: 30px; color: #9eb08e; }
.empty-state strong { display: block; color: #5f7951; font-size: 15px; font-weight: 550; }
.field { display: block; margin-bottom: 15px; min-width: 0; }
.field > span, .field > label { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; margin-bottom: 7px; color: #617858; font-size: 12px; font-weight: 550; line-height: 1.45; }
.field input:not([type="checkbox"]):not([type="radio"]), .field select, .field textarea { width: 100%; min-height: 41px; padding: 10px 11px; border: 1px solid #d6deca; border-radius: 6px; background: #fffefa; font-size: 14px; line-height: 1.4; }
.field input:hover, .field textarea:hover, .field select:hover { border-color: #adbf9d; }
.field textarea { min-height: 108px; line-height: 1.7; resize: vertical; }
.field input::placeholder, .field textarea::placeholder { color: #98a48a; }
.field small { display: block; margin-top: 6px; color: #8b9b7a; font-size: 12px; line-height: 1.5; }
.field-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.field-row.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.field.error input, .field.error textarea, .field.error select { border-color: var(--danger); }
.field.error small { color: var(--danger); }
.toggle { display: inline-flex; align-items: flex-start; gap: 8px; padding: 7px 0; font-size: 12px; color: #6b815f; line-height: 1.6; cursor: pointer; }
.toggle input { margin-top: 1px; }
.chip { min-height: 30px; padding: 5px 9px; border: 1px solid #dce3d1; border-radius: 5px; background: #f7f9f1; color: #7f926f; font-size: 12px; line-height: 1.3; }
.chip:hover { border-color: #a4ba91; background: #edf4e2; }
.chip.active { border-color: #8fa77a; background: #e3edd7; color: #476333; }
.segmented, .view-switch { display: inline-flex; align-items: center; gap: 3px; padding: 3px; border: 1px solid #dfe5d5; border-radius: 7px; background: #ecefe3; }
.segmented button, .view-switch button { min-height: 31px; padding: 6px 12px; border: 0; border-radius: 4px; background: transparent; color: #7d8e70; font-size: 12px; font-weight: 550; display: inline-flex; align-items: center; justify-content: center; gap: 6px; }
.segmented button.active, .view-switch button.active { color: var(--ink); background: #fffefa; box-shadow: 0 1px 5px rgb(36 60 24 / 8%); }
.segmented button:hover, .view-switch button:hover { color: var(--ink); }

/* A welcoming, architectural opening rather than a generic dashboard. */
.welcome-page { max-width: 1520px; margin: 0 auto; padding: 42px 40px 48px; }
.welcome-hero { display: grid; grid-template-columns: minmax(340px, .95fr) minmax(0, 1.15fr); align-items: center; gap: 48px; margin-bottom: 48px; }
.hero-copy { padding: 12px 0; max-width: 535px; }
.hero-copy .eyebrow { color: #8a987a; margin-bottom: 18px; }
.hero-copy h1 { font-family: var(--serif); font-size: clamp(42px, 4.1vw, 62px); font-weight: 400; line-height: 1.055; letter-spacing: -.045em; margin-bottom: 22px; }
.hero-copy h1 em { color: #9a6c4b; font-weight: 400; }
.hero-copy > p { max-width: 455px; color: #7c8b70; font-size: 15px; line-height: 1.8; }
.hero-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin-top: 27px; }
.hero-actions .btn { min-height: 45px; padding: 12px 18px; font-size: 14px; }
.hero-proof { display: flex; align-items: center; flex-wrap: wrap; gap: 12px 22px; margin-top: 24px; color: #8a987c; font-size: 12px; }
.hero-proof > span { display: inline-flex; align-items: center; gap: 7px; }
.hero-proof .icon { width: 14px; height: 14px; flex-basis: 14px; color: #779463; }
.hero-scene { position: relative; isolation: isolate; height: 480px; min-width: 0; overflow: hidden; background: #e9eddf; border: 1px solid #e0e5d5; border-radius: 23px; box-shadow: inset 0 0 50px rgb(255 255 246 / 55%); }
.hero-scene::before { content: ""; position: absolute; inset: 0; z-index: -1; background: radial-gradient(ellipse at 45% 35%, #fcf9ed 0%, #edf0e1 55%, #e1e7d5 100%); }
#hero-3d { width: 100%; height: 100%; min-height: 0; }
#hero-3d canvas, #hero-3d svg { width: 100%; height: 100%; display: block; }
.hero-scene-caption { position: absolute; left: 19px; right: 19px; bottom: 17px; z-index: 2; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 14px; border: 1px solid rgb(255 255 246 / 75%); border-radius: 9px; background: rgb(250 250 239 / 85%); backdrop-filter: blur(6px); font-size: 12px; color: #7a8d68; pointer-events: none; }
.hero-scene-caption strong { font-size: 13px; font-weight: 550; color: #446535; }
.hero-scene-caption .badge { background: #e1ebd4; }
.section-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 20px; }
.section-heading h2 { font-family: var(--serif); font-size: 29px; font-weight: 400; line-height: 1.2; letter-spacing: -.03em; }
.section-heading p { max-width: 560px; color: #819173; font-size: 13px; line-height: 1.7; }
.start-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 17px; margin-bottom: 43px; }
.start-card { position: relative; display: block; width: 100%; min-height: 219px; padding: 23px 23px 25px; text-align: left; border: 1px solid #dfe6d2; border-radius: 13px; background: #fdfdf7; transition: border-color .18s, box-shadow .18s, transform .18s; }
.start-card:hover { border-color: #9bb284; box-shadow: 0 9px 26px rgb(33 62 22 / 6%); transform: translateY(-2px); }
.start-icon { display: grid; place-items: center; width: 43px; height: 43px; border: 1px solid #d8e4c8; border-radius: 9px; background: #edf3e2; color: #6b8a55; margin-bottom: 17px; }
.start-icon .icon { width: 23px; height: 23px; flex-basis: 23px; }
.start-card:nth-child(2) .start-icon { background: #f4ece0; border-color: #eadcc7; color: #9d7955; }
.start-card:nth-child(3) .start-icon { background: #e7eeea; border-color: #cdded5; color: #6d8e7b; }
.start-card h3 { font-size: 18px; font-weight: 560; letter-spacing: -.025em; line-height: 1.3; margin-bottom: 9px; }
.start-card p { max-width: 300px; padding-right: 22px; color: #829471; font-size: 13px; line-height: 1.75; }
.start-card > .arrow { position: absolute; right: 19px; bottom: 23px; display: grid; place-items: center; width: 29px; height: 29px; border-radius: 50%; background: #edf4e3; color: #7b9568; }
.start-card > .arrow .icon { width: 16px; height: 16px; }
.project-gallery, .saved-gallery { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; margin-bottom: 40px; }
.project-card { min-width: 0; overflow: hidden; border: 1px solid #dfe6d2; border-radius: 14px; background: #fdfdf8; transition: border-color .16s, box-shadow .16s; }
.project-card:hover { border-color: #b0c49c; box-shadow: var(--shadow); }
.project-thumbnail { display: flex; align-items: center; justify-content: center; width: 100%; height: 222px; padding: 0; overflow: hidden; border: 0; border-bottom: 1px solid #e0e7d4; background: #eef2e3; }
.project-thumbnail svg, .project-thumbnail img, .project-thumbnail canvas { width: 100%; height: 100%; object-fit: contain; }
.project-thumbnail svg { padding: 11px; }
.project-card-body { padding: 19px 21px 21px; }
.project-card-top { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.project-name { font-family: var(--serif); font-size: 24px; font-weight: 400; line-height: 1.3; letter-spacing: -.025em; }
.project-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 7px 13px; margin-top: 11px; color: #879774; font-size: 12px; line-height: 1.5; }
.project-meta > span { display: inline-flex; align-items: center; gap: 5px; }
.project-meta .icon { width: 14px; height: 14px; flex-basis: 14px; }
.project-card-body > p { color: #849873; font-size: 13px; line-height: 1.75; margin-top: 11px; }
.project-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 7px; margin-top: 18px; padding-top: 16px; border-top: 1px solid #e6ecdc; }
.project-actions .btn { flex: 1 0 auto; }
.project-actions .btn.icon { flex: 0 0 36px; }
.book-strip { display: flex; align-items: center; justify-content: space-between; gap: 25px; padding: 25px 29px; border: 1px solid #2f5746; border-radius: 13px; background: #21483e; color: #f6f5e9; }
.book-strip h3 { font-family: var(--serif); font-size: 24px; font-weight: 400; margin-bottom: 5px; letter-spacing: -.02em; }
.book-strip p { font-size: 13px; color: #bccdb1; line-height: 1.7; }
.book-strip .eyebrow { color: #a2ba93; margin-bottom: 7px; }
.book-strip .btn { flex-shrink: 0; background: #f1f3e6; border-color: #dbe4ca; color: #2c4c25; }
.book-strip .icon { width: 29px; height: 29px; }

/* Full-width drawing studio: the plan gets the space, tools stay close. */
.studio-workspace { display: grid; grid-template-columns: 240px minmax(0, 1fr) 300px; height: calc(100dvh - var(--header-height)); min-height: 660px; overflow: hidden; }
.studio-sidebar { display: flex; flex-direction: column; min-width: 0; min-height: 0; padding: 20px 16px; background: #f7f8f0; border-right: 1px solid var(--line); overflow-y: auto; }
.project-heading { margin-bottom: 19px; padding-inline: 3px; }
.project-heading h2 { font-family: var(--serif); font-size: 24px; font-weight: 400; line-height: 1.25; letter-spacing: -.025em; margin: 7px 0; }
.project-heading p { color: #849676; font-size: 12px; line-height: 1.65; }
.project-select { font-size: 13px; margin-top: 8px; }
.sidebar-section { flex: 0 0 auto; padding-top: 19px; margin-top: 19px; border-top: 1px solid #dfe7d3; }
.sidebar-section .section-heading { align-items: center; gap: 8px; margin-bottom: 12px; }
.sidebar-section .section-heading h2, .sidebar-section .section-heading h3 { font-family: var(--font); font-size: 12px; font-weight: 650; line-height: 1.5; letter-spacing: .05em; text-transform: uppercase; }
.sidebar-section .section-heading p, .sidebar-section .section-heading span { font-size: 12px; color: #8b9a7b; }
.sidebar-section .btn { width: 100%; }
.room-list { display: grid; gap: 7px; }
.room-row { display: flex; align-items: center; gap: 9px; width: 100%; min-width: 0; padding: 10px 9px; border: 1px solid #e4eada; border-radius: 7px; background: #fdfdf7; text-align: left; transition: background .14s, border-color .14s; }
.room-row:hover { border-color: #b7cba3; background: #f2f7e9; }
.room-row.active { border-color: #8fa67d; background: #eaf2df; box-shadow: inset 2px 0 0 #5f814a; }
.room-dot { width: 9px; height: 9px; flex: 0 0 9px; border: 1px solid rgb(40 60 20 / 12%); border-radius: 2px; background: #c8d8b6; }
.room-row-copy { flex: 1; min-width: 0; }
.room-row-copy strong { display: block; color: #4b693d; font-size: 12px; font-weight: 580; line-height: 1.4; }
.room-row-copy small { display: block; font-size: 12px; line-height: 1.35; color: #94a37f; margin-top: 3px; }
.room-area { font-size: 12px; color: #83986e; white-space: nowrap; }
.sidebar-actions { display: flex; flex-direction: column; gap: 7px; padding-top: 19px; margin-top: auto; }
.sidebar-actions .btn { width: 100%; }
.studio-canvas { display: flex; flex-direction: column; min-width: 0; min-height: 0; background: #f2f4e8; overflow: hidden; }
.canvas-heading { display: flex; justify-content: space-between; align-items: center; gap: 15px; padding: 22px 25px 18px; background: var(--paper-light); border-bottom: 1px solid #e3e8d8; flex: 0 0 auto; }
.canvas-heading h1 { margin: 5px 0 4px; font-family: var(--serif); font-size: 28px; font-weight: 400; line-height: 1.15; letter-spacing: -.03em; }
.canvas-heading p { color: #849676; font-size: 12px; line-height: 1.65; }
.canvas-heading-actions { display: flex; justify-content: flex-end; align-items: center; flex-wrap: wrap; gap: 5px; flex-shrink: 0; }
.canvas-bar { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 11px 18px; background: #fafbf4; border-bottom: 1px solid #e3e9d7; flex: 0 0 auto; }
.canvas-tools { display: flex; align-items: center; gap: 5px; }
.canvas-tools .btn.icon { width: 32px; height: 32px; min-height: 32px; flex-basis: 32px; padding: 7px; }
.canvas-tools .btn.small { min-height: 32px; padding: 6px 8px; }
.canvas-tools .toggle { padding: 0 3px; }
.canvas-tools .divider { height: 21px; width: 1px; margin: 0 4px; }
.zoom-label { min-width: 38px; font-size: 12px; text-align: center; color: #829675; }
.canvas-stage { position: relative; display: flex; align-items: flex-start; justify-content: flex-start; flex: 1 1 auto; min-width: 0; min-height: 300px; overflow: auto; background: #f3f5e9; touch-action: pan-x pan-y; overscroll-behavior: contain; isolation: isolate; }
.canvas-stage.is-3d { overflow: hidden; background: #edf1e3; touch-action: none; }
#drawing-inner { position: relative; display: flex; align-items: center; justify-content: center; flex: 0 0 auto; width: 100%; height: 100%; min-height: 300px; }
#drawing-inner > svg { display: block; width: 100%; height: 100%; min-height: 300px; user-select: none; -webkit-user-select: none; }
#drawing-inner [data-room-id], #drawing-inner [data-opening-id] { cursor: grab; touch-action: none; }
#drawing-inner [data-furniture-id] { cursor: grab; touch-action: none; }
#drawing-inner [data-furniture-id]:active { cursor: grabbing; }
.three-stage { position: absolute; inset: 0; min-height: 0; }
.three-stage > canvas, .three-stage > svg { width: 100%; height: 100%; display: block; touch-action: none; }
.canvas-hint { position: absolute; left: 50%; bottom: 15px; z-index: 3; transform: translateX(-50%); width: max-content; max-width: calc(100% - 32px); padding: 8px 12px; background: rgb(252 252 244 / 89%); border: 1px solid rgb(212 223 194 / 80%); border-radius: 7px; backdrop-filter: blur(5px); color: #7b9169; font-size: 12px; line-height: 1.55; text-align: center; pointer-events: none; }
.canvas-hint .icon { display: inline-block; width: 14px; height: 14px; vertical-align: -3px; margin-right: 4px; }
.canvas-bottom { flex: 0 0 auto; padding: 0 22px 14px; background: #f8faf0; border-top: 1px solid #dde6cf; }
.metrics-row { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.metric { padding: 16px 13px 12px; min-width: 0; }
.metric + .metric { border-left: 1px solid #e1e8d6; }
.metric strong { display: block; font-size: 23px; line-height: 1.2; font-weight: 550; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.metric > span { display: block; font-size: 12px; line-height: 1.4; margin-top: 5px; color: #80956e; }
.progress-track { height: 4px; overflow: hidden; background: #dfe9d2; border-radius: 10px; margin: 4px 12px 0; }
.progress-fill { height: 100%; background: #75935f; border-radius: inherit; transition: width .18s; }
.validation-summary { flex: 0 0 auto; display: flex; align-items: center; gap: 8px; width: 100%; min-height: 37px; padding: 9px 12px; border: 0; border-top: 1px solid #e0e8d4; background: #f6f9ef; color: #617952; font-size: 12px; line-height: 1.5; text-align: left; }
.validation-summary .icon { width: 15px; height: 15px; flex-basis: 15px; }
.validation-summary .text-button { margin-left: auto; }
.studio-inspector { min-width: 0; min-height: 0; display: flex; flex-direction: column; background: #fdfef8; border-left: 1px solid var(--line); overflow: hidden; }
.inspector-tabs { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 1px; padding: 6px; border-bottom: 1px solid #e2e9d6; background: #f4f7ec; flex: 0 0 auto; }
.inspector-tabs button { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 5px; min-width: 0; min-height: 58px; padding: 8px 2px; border: 1px solid transparent; border-radius: 6px; background: transparent; color: #8a9c78; font-size: 12px; line-height: 1.25; }
.inspector-tabs button .icon { width: 17px; height: 17px; }
.inspector-tabs button:hover { color: #577942; background: #eaf2df; }
.inspector-tabs button.active { background: #fffefa; border-color: #dde7ce; color: #486a34; box-shadow: 0 2px 6px rgb(30 62 18 / 5%); }
.inspector-body { flex: 1; min-height: 0; overflow-y: auto; padding: 20px 18px 25px; }
.inspector-body h2 { font-family: var(--serif); font-size: 24px; font-weight: 400; letter-spacing: -.03em; line-height: 1.25; margin: 7px 0 8px; }
.inspector-body > p { font-size: 12px; line-height: 1.7; margin-bottom: 16px; }
.inspector-body h3 { font-size: 13px; font-weight: 600; line-height: 1.4; }
.inspector-body .section-heading { align-items: center; gap: 7px; margin-bottom: 12px; }
.inspector-body .section-heading h2, .inspector-body .section-heading h3 { font-family: var(--font); font-size: 12px; font-weight: 650; letter-spacing: .035em; text-transform: uppercase; margin: 0; }
.inspector-body .section-heading span { color: #8c9d7b; font-size: 12px; }
.selected-card { margin: 15px 0 20px; padding: 15px; border: 1px solid #d7e3c8; border-radius: 9px; background: #eef5e3; }
.selected-card h3 { font-size: 14px; font-weight: 600; margin-bottom: 8px; }
.selected-card .field { margin-bottom: 12px; }
.selected-card .field-row { gap: 9px; }
.selected-card .field > span { font-size: 12px; }
.selected-card p { font-size: 12px; color: #7b9369; line-height: 1.65; }
.selected-card .btn { margin-top: 5px; }
.furniture-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.furniture-card { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; min-height: 98px; padding: 12px 7px; border: 1px solid #dfe8d2; border-radius: 8px; background: #f9fcf2; font-size: 12px; color: #6b8757; text-align: center; transition: background .15s, border-color .15s; }
.furniture-card:hover { background: #eef6e1; border-color: #a2bc8b; }
.furniture-card > svg, .furniture-card .icon { width: 36px; height: 29px; flex: 0 0 29px; color: #7a9665; }
.furniture-card small { display: block; font-size: 12px; color: #95a783; line-height: 1.3; }
.furniture-card strong { font-size: 12px; font-weight: 550; }
.opening-list { display: grid; gap: 8px; margin: 14px 0; }
.opening-list button { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 47px; padding: 11px; border: 1px solid #dfe8d2; border-radius: 7px; background: #f9fcf2; text-align: left; color: #688453; font-size: 13px; }
.opening-list button:hover, .opening-list button.active { border-color: #a2ba8f; background: #edf5e1; }
.opening-list small { display: block; font-size: 12px; color: #92a57e; }
.material-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; margin: 13px 0 20px; }
.material-card { display: block; min-width: 0; padding: 7px 7px 11px; border: 1px solid #dbe5ce; border-radius: 8px; background: #f9fcf1; color: #6a8654; text-align: left; font-size: 12px; }
.material-card:hover { border-color: #a1b58f; background: #f3f8e9; }
.material-card.active, .material-card.selected { border-color: #789263; box-shadow: 0 0 0 1px #789263; background: #edf4e2; }
.material-preview { position: relative; display: block; height: 69px; overflow: hidden; border-radius: 4px; margin-bottom: 9px; background: #d8dfc9; box-shadow: inset 0 0 0 1px rgb(39 51 23 / 7%); }
.material-preview svg, .material-preview img { width: 100%; height: 100%; object-fit: cover; }
.material-card strong { display: block; font-size: 12px; font-weight: 550; padding-inline: 2px; }
.swatch-row { display: flex; align-items: center; gap: 5px; padding: 7px 2px 0; }
.swatch-row > span, .swatch-row > i { display: block; width: 13px; height: 13px; border-radius: 50%; border: 1px solid rgb(31 45 16 / 15%); }
.review-list { display: grid; gap: 9px; margin: 16px 0; padding: 0; list-style: none; }
.review-item { display: flex; align-items: flex-start; gap: 9px; padding: 12px 13px; border: 1px solid #dce6d0; border-left: 3px solid #a4bc8d; border-radius: 6px; background: #f1f7e8; color: #536f41; font-size: 12px; line-height: 1.65; overflow-wrap: anywhere; }
.review-item strong { display: block; font-weight: 600; margin-bottom: 4px; }
.review-item.error { color: #9c5b48; background: #fbede4; border-color: #eed4c4; border-left-color: #bd7960; }
.review-item.warning { color: #947942; background: #faf3df; border-color: #e8dfbd; border-left-color: #bdac71; }
.settings-section { margin-top: 20px; padding-top: 19px; border-top: 1px solid #e0e9d4; }
.settings-section h3 { margin-bottom: 12px; }
.project-tools { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 15px; }
.project-tools .btn { flex: 1 0 auto; }

/* Guided creation, plan suggestions and project actions. */
.modal-backdrop { position: fixed; z-index: 100; inset: 0; display: flex; align-items: center; justify-content: center; padding: 24px; background: rgb(17 38 24 / 48%); backdrop-filter: blur(6px); }
.modal { display: flex; flex-direction: column; width: min(720px, 100%); max-height: min(90dvh, 950px); min-width: 0; overflow: hidden; border: 1px solid #d9e3cb; border-radius: 15px; background: #fdfef7; box-shadow: 0 25px 110px rgb(17 43 18 / 22%); }
.modal.wide { width: min(1180px, 100%); }
.modal.wizard-modal { width: min(1000px, 100%); }
.modal-header { display: flex; justify-content: space-between; align-items: flex-start; gap: 20px; padding: 23px 25px; border-bottom: 1px solid #e1e9d4; flex: 0 0 auto; }
.modal-header h2, .modal-title { font-family: var(--serif); font-size: 28px; font-weight: 400; letter-spacing: -.035em; line-height: 1.2; }
.modal-header p { font-size: 13px; color: #839674; margin-top: 7px; line-height: 1.6; }
.close-btn { display: grid; place-items: center; width: 33px; height: 33px; flex: 0 0 33px; padding: 7px; border: 1px solid #dde6d1; border-radius: 6px; background: #f4f8eb; color: #809772; }
.close-btn:hover { background: #e7f0db; border-color: #b9cda4; color: #55733f; }
.close-btn .icon { width: 17px; height: 17px; }
.modal-body { min-height: 0; overflow-y: auto; padding: 24px 25px; }
.modal-body > p { font-size: 13px; line-height: 1.75; margin-bottom: 16px; }
.modal-body > img { width: 100%; height: auto; }
.modal-footer { display: flex; align-items: center; justify-content: flex-end; gap: 9px; padding: 17px 25px; border-top: 1px solid #dfe8d2; background: #f8faf0; flex: 0 0 auto; }
.modal-footer .btn:first-child:not(:last-child) { margin-right: auto; }
.wizard-stepper { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 8px; padding-bottom: 18px; border-bottom: 1px solid #e3ebd8; }
.wizard-stepper > span, .wizard-stepper > div, .wizard-stepper > button { display: flex; align-items: center; gap: 9px; border: 0; padding: 8px 4px; background: transparent; color: #667e55; font-size: 12px; line-height: 1.4; text-align: left; }
.wizard-stepper > .active { color: #4b6f33; font-weight: 550; }
.wizard-stepper i, .wizard-stepper .step-number, .wizard-stepper > div > span:first-child, .wizard-stepper > button > span:first-child { display: grid; place-items: center; width: 25px; height: 25px; flex: 0 0 25px; border-radius: 50%; background: #e9f1dc; color: #687f56; font-size: 12px; font-style: normal; }
.wizard-stepper .active i, .wizard-stepper .active .step-number, .wizard-stepper > .active > span:first-child { color: #f6faec; background: #567744; }
.wizard-heading { margin: 22px 0; }
.wizard-heading h2, .wizard-heading h3 { font-family: var(--serif); font-size: 29px; font-weight: 400; letter-spacing: -.03em; line-height: 1.25; margin-bottom: 8px; }
.wizard-heading p { color: #849873; font-size: 13px; line-height: 1.7; }
.wizard-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(270px, .86fr); gap: 27px; align-items: start; }
.wizard-summary { position: sticky; top: 0; padding: 20px; border: 1px solid #dce7cd; border-radius: 11px; background: #eff5e5; }
.wizard-summary h3 { margin-bottom: 13px; font-size: 14px; font-weight: 550; }
.wizard-summary > svg, .wizard-summary .footprint-preview > svg, #wizard-footprint > svg { width: 100%; height: 210px; }
.wizard-summary p { font-size: 12px; color: #7f956c; line-height: 1.7; margin-top: 11px; }
.wizard-summary .metric strong { font-size: 24px; }
.option-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin: 14px 0; }
.choice-card { display: flex; align-items: flex-start; gap: 10px; min-width: 0; padding: 14px; border: 1px solid #dde7d0; border-radius: 8px; background: #fbfdf5; cursor: pointer; }
.choice-card:hover { border-color: #aabe94; }
.choice-card.active, .choice-card.selected, .choice-card:has(input:checked) { background: #edf5e0; border-color: #97b080; box-shadow: inset 0 0 0 1px #97b080; }
.choice-card input { margin-top: 2px; }
.choice-card strong { display: block; font-size: 13px; font-weight: 550; line-height: 1.5; }
.choice-card small, .choice-card p { display: block; margin-top: 4px; color: #8c9f78; font-size: 12px; line-height: 1.6; }
.generated-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; align-items: start; }
.generated-card { min-width: 0; overflow: hidden; padding: 17px; border: 1px solid #dbe7cc; border-radius: 11px; background: #fbfdf4; }
.generated-card.active, .generated-card.selected { border-color: #789a5b; box-shadow: 0 0 0 1px #789a5b; }
.generated-card > svg, .generated-card .generated-preview > svg { display: block; width: 100%; height: 205px; background: #f0f6e5; border-radius: 6px; margin-bottom: 13px; }
.generated-card h3 { font-family: var(--serif); font-size: 23px; font-weight: 400; line-height: 1.25; letter-spacing: -.02em; margin: 10px 0 7px; }
.generated-card p { font-size: 12px; color: #839b6d; line-height: 1.7; }
.generated-card .metrics-row { grid-template-columns: repeat(2, minmax(0, 1fr)); margin-top: 12px; }
.generated-card .metric { padding: 10px 6px; }
.generated-card .metric strong { font-size: 18px; }
.generated-card .btn { width: 100%; margin-top: 16px; }
.export-options { display: grid; gap: 10px; margin: 17px 0; }
.export-option { display: flex; align-items: center; gap: 15px; width: 100%; padding: 17px; border: 1px solid #dce8cd; border-radius: 8px; background: #f6faee; text-align: left; }
.export-option:hover { background: #edf6e0; border-color: #a4be8c; }
.export-option > span { flex: 1; display: block; }
.export-option strong { display: block; color: #4b6d36; font-size: 14px; font-weight: 550; }
.export-option small { display: block; color: #8b9e77; font-size: 12px; line-height: 1.6; margin-top: 4px; }

/* Comparison, saved versions and the printable owner brief. */
.content-page { width: min(1450px, 100%); margin: 0 auto; padding: 35px 35px 45px; }
.content-page > h1, .page-heading h1 { font-family: var(--serif); font-size: 39px; font-weight: 400; line-height: 1.2; letter-spacing: -.04em; margin: 8px 0 12px; }
.content-page > p, .page-heading > p { max-width: 850px; color: #829674; font-size: 14px; line-height: 1.8; }
.page-heading { margin-bottom: 28px; }
.compare-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 21px; margin-top: 26px; align-items: start; }
.compare-card { min-width: 0; padding: 21px; border: 1px solid #dce7ce; border-radius: 13px; background: #fdfef7; }
.compare-card.active, .compare-card.chosen { border-color: #8da975; box-shadow: inset 0 3px 0 #719355; }
.compare-card h2 { font-family: var(--serif); font-size: 26px; font-weight: 400; line-height: 1.25; letter-spacing: -.025em; margin: 12px 0 9px; }
.compare-card p, .compare-card li { font-size: 13px; color: #829974; line-height: 1.75; }
.compare-card-heading { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 7px; }
.compare-preview, .compare-plan { height: 240px; margin: 17px -6px; padding: 6px; background: #f0f6e5; border-radius: 6px; }
.compare-preview svg, .compare-plan svg, .compare-card > svg { width: 100%; height: 240px; }
.compare-row { display: flex; justify-content: space-between; align-items: flex-start; gap: 15px; padding: 12px 0; border-bottom: 1px solid #e2ead6; font-size: 12px; }
.compare-label { color: #869c76; }
.compare-value { color: #52743e; font-size: 13px; font-weight: 550; text-align: right; }
.compare-points { margin-top: 20px; }
.compare-points h3 { margin-top: 17px; font-size: 12px; font-weight: 650; letter-spacing: .045em; text-transform: uppercase; }
.compare-points ul { margin-top: 9px; }
.compare-actions { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 20px; }
.compare-actions .btn { flex: 1; }
.comparison-note { display: flex; align-items: flex-start; gap: 9px; margin-top: 23px; font-size: 12px; color: #8b9f7a; line-height: 1.7; }
.version-list { display: grid; gap: 12px; margin-top: 20px; }
.version-card { display: grid; grid-template-columns: 140px minmax(0, 1fr); align-items: center; gap: 19px; padding: 15px; border: 1px solid #dce7ce; border-radius: 10px; background: #fafdf3; }
.version-card > svg, .version-preview { width: 140px; height: 105px; padding: 4px; background: #eef5e2; border-radius: 5px; }
.version-preview svg, .version-preview img { width: 100%; height: 100%; object-fit: contain; }
.version-card h3 { font-size: 16px; font-weight: 550; line-height: 1.4; margin-bottom: 6px; }
.version-card p, .version-card small { font-size: 12px; color: #8a9e79; line-height: 1.6; }
.version-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 7px; }
.brief-layout { display: grid; grid-template-columns: minmax(320px, 430px) minmax(0, 1fr); gap: 25px; margin-top: 26px; align-items: start; }
.brief-form, .brief-preview { min-width: 0; padding: 25px; border: 1px solid #dce7cf; border-radius: 12px; background: #fdfef8; }
.brief-form h2 { font-family: var(--serif); font-size: 26px; font-weight: 400; letter-spacing: -.025em; line-height: 1.3; margin-bottom: 20px; }
.brief-preview { background: #fffefa; box-shadow: var(--shadow); }
.brief-paper h2 { font-family: var(--serif); font-size: 29px; font-weight: 400; line-height: 1.25; letter-spacing: -.035em; margin: 12px 0 9px; }
.brief-paper p, .brief-paper li { font-size: 13px; color: #80976f; line-height: 1.8; overflow-wrap: anywhere; }
.brief-paper-header { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.brief-plan-preview { height: 310px; margin: 21px -8px 17px; padding: 6px; border-radius: 7px; background: #f3f8e9; }
.brief-plan-preview svg { width: 100%; height: 100%; }
.brief-area-line { display: flex; justify-content: space-between; gap: 12px; padding: 14px 0; border-top: 1px solid #dfe9d1; border-bottom: 1px solid #dfe9d1; color: #8aa077; font-size: 12px; }
.brief-area-line strong { color: #567740; font-size: 15px; font-weight: 550; }
.brief-preview-section { margin-top: 23px; }
.brief-preview-section h3 { font-size: 12px; font-weight: 650; letter-spacing: .05em; text-transform: uppercase; margin-bottom: 8px; }
.priority-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px 13px; margin: 11px 0 20px; }
.priority-fieldset { min-width: 0; margin: 20px 0; padding: 0; border: 0; }
.priority-fieldset legend { padding: 0; color: #688459; font-size: 12px; font-weight: 550; }
.checklist-row { display: flex; align-items: flex-start; gap: 8px; padding: 5px 0; color: #768f64; font-size: 12px; line-height: 1.6; cursor: pointer; }
.priority-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.priority-tags > span { padding: 5px 8px; border-radius: 4px; background: #edf5e0; color: #7a9469; font-size: 12px; }
.budget-details { margin-top: 23px; padding-top: 18px; border-top: 1px solid #dfe8d2; }
.budget-details > summary { font-size: 13px; font-weight: 550; color: #5c7c49; cursor: pointer; }
.budget-details > summary .muted { float: right; font-size: 12px; font-weight: 400; }
.budget-details[open] > summary { margin-bottom: 12px; }
.budget-total { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 15px; margin-top: 15px; border: 1px solid #d9e6c9; border-radius: 7px; background: #eef6e1; color: #7b956a; font-size: 12px; }
.budget-total strong { color: var(--ink); font-size: 23px; font-weight: 550; letter-spacing: -.03em; }
.export-actions { display: flex; flex-wrap: wrap; gap: 8px; padding-top: 18px; margin-top: 21px; border-top: 1px solid #dfe9d1; }
.export-actions .btn { flex: 1 0 auto; }
.source-note { font-size: 12px; color: #91a181; line-height: 1.7; margin-top: 20px; }
.source-note h3 { font-size: 13px; color: #7a9269; margin-bottom: 8px; }
.toast { position: fixed; z-index: 140; left: 50%; bottom: 24px; transform: translate(-50%, 12px); max-width: min(580px, calc(100vw - 32px)); width: max-content; padding: 13px 19px; background: #244a3c; color: #f7f9eb; border: 1px solid #386349; border-radius: 9px; box-shadow: 0 10px 40px rgb(26 48 21 / 18%); font-size: 13px; line-height: 1.6; opacity: 0; visibility: hidden; pointer-events: none; transition: opacity .18s, transform .18s, visibility .18s; }
.toast.visible { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
.toast.error { color: #fff5ec; background: #975844; border-color: #b97760; }
.studio-footer { display: flex; justify-content: space-between; gap: 20px; padding: 16px 28px; background: #f4f8ec; border-top: 1px solid #dfe8d2; color: #667c57; font-size: 12px; }
.print-only { display: none; }

/* Details tied to the live editor and its project model. */
.hero-scene-caption > div { text-align: right; }
.hero-scene-caption > div > strong, .hero-scene-caption > div > span { display: block; }
.hero-scene-caption > div > span { margin-top: 3px; }
.section-heading .eyebrow { margin-bottom: 8px; }
.start-card > span:not(.start-icon):not(.arrow) { display: block; }
.start-card.accent { background: #faf7ef; border-color: #e4ddce; }
.favorite-btn { display: grid; place-items: center; flex: 0 0 32px; width: 32px; height: 32px; padding: 7px; border: 1px solid transparent; border-radius: 50%; background: transparent; color: #7c8978; }
.favorite-btn:hover, .favorite-btn.active { color: #a76645; border-color: #e8d9c9; background: #f7eade; }
.favorite-btn.active .icon { fill: #f0d6c4; }
.project-card-top .eyebrow { flex: 1; }
.book-icon { display: grid; place-items: center; flex: 0 0 47px; width: 47px; height: 57px; border: 1px solid #719076; border-radius: 6px; color: #d0dcbe; }
.book-strip > div { flex: 1; }
.room-list { margin-bottom: 12px; }
.footprint-mini strong { display: block; font-size: 25px; font-weight: 500; letter-spacing: -.03em; }
.footprint-mini small, .metric strong small { font-size: 12px; font-weight: 450; letter-spacing: 0; color: #6d8061; }
.footprint-mini > span { display: block; font-size: 12px; color: #687b5e; margin-top: 2px; }
.allocation { margin-top: 14px; font-size: 12px; color: #6b7f60; }
.allocation > div:first-child { display: flex; justify-content: space-between; gap: 8px; }
.allocation strong { font-weight: 550; color: #46643c; }
.allocation .progress-track { margin: 8px 0; }
.allocation > small { display: block; font-size: 12px; }
.btn.ghost.active { background: #dde9d0; color: #355d2f; border-color: #b7cba7; }
.review-link { display: inline-flex; align-items: center; gap: 3px; white-space: nowrap; margin-left: auto; color: #49673b; }
.inspector-intro { margin-bottom: 22px; }
.inspector-intro > p { color: #6d7d65; font-size: 13px; line-height: 1.7; }
.inspector-body > .btn + .field-row { margin-top: 10px; }
.category-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 18px 0 14px; }
.opening-row > span { flex: 1; min-width: 0; }
.opening-row strong { font-size: 13px; font-weight: 550; }
.material-card-title { display: flex; align-items: center; justify-content: space-between; gap: 5px; font-size: 12px; font-weight: 600; line-height: 1.45; }
.material-card-title .icon { width: 13px; height: 13px; flex-basis: 13px; }
.material-card > small { display: block; margin-top: 9px; color: #6c7c61; font-size: 12px; line-height: 1.5; }
.material-preview { --wall: #f5f0e6; --floor: #bf9b6d; --sofa: #758b78; }
.material-preview.rustic { --wall: #cfb38d; --floor: #997249; --sofa: #795642; }
.material-preview.contemporary { --wall: #e4e1d7; --floor: #c6c3ba; --sofa: #414c4c; }
.material-wall { position: absolute; inset: 0 0 34%; background: var(--wall); box-shadow: inset 15px 0 20px rgb(78 60 27 / 5%); }
.material-wall::after { content: ""; position: absolute; top: 15%; left: 12%; width: 22%; height: 49%; border: 3px solid #fbfaf1; background: #c4d4cd; box-shadow: 1px 2px 3px rgb(39 50 36 / 10%); }
.material-floor { position: absolute; inset: 65% 0 0; background: repeating-linear-gradient(0deg, transparent 0 7px, rgb(67 48 29 / 11%) 7px 8px), var(--floor); }
.material-sofa { position: absolute; right: 11%; top: 40%; width: 48%; height: 31%; border: 4px solid rgb(255 255 255 / 9%); border-radius: 6px 6px 2px 2px; background: var(--sofa); box-shadow: 0 4px 5px rgb(30 40 25 / 14%); }
.material-sofa::after { content: ""; position: absolute; inset: 43% 0 0; border-top: 1px solid rgb(255 255 255 / 30%); }
.review-item > .icon { margin-top: 2px; width: 15px; height: 15px; flex-basis: 15px; }
.empty-note { padding: 14px; border: 1px dashed #ced9bf; border-radius: 7px; color: #6d825f; font-size: 12px; line-height: 1.7; }
.blank-canvas-note { position: absolute; z-index: 4; inset: 50% auto auto 50%; transform: translate(-50%, -50%); width: min(390px, calc(100% - 36px)); padding: 25px; border: 1px solid #d4dfc7; border-radius: 12px; background: rgb(255 254 246 / 95%); box-shadow: 0 10px 45px rgb(32 57 30 / 8%); text-align: center; }
.blank-canvas-note h2 { font-family: var(--serif); font-size: 27px; font-weight: 400; letter-spacing: -.03em; margin: 10px 0; }
.blank-canvas-note p { color: #667b5d; font-size: 13px; line-height: 1.7; margin-bottom: 15px; }
.blank-canvas-note .btn { margin: 4px; }
.scene-fallback { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; width: 100%; height: 100%; padding: 25px 25px 80px; text-align: center; color: #677b5a; font-size: 12px; }
.fallback-plan { width: 100%; min-height: 100px; flex: 1; overflow: hidden; }
.fallback-plan svg { width: 100%; height: 100%; }
.form-error, .generation-error { margin: 14px 0; padding: 13px 15px; border: 1px solid #dfb8a5; border-radius: 7px; background: #fbeddf; color: #925840; font-size: 13px; line-height: 1.7; }
.generation-error h3 { font-size: 16px; font-weight: 550; margin-bottom: 7px; }
.generation-error p + p { margin-top: 7px; }
.generation-notes { margin-top: 20px; color: #697c60; font-size: 12px; line-height: 1.7; }
.generation-notes p + p { margin-top: 6px; }
.generated-card > p { margin-top: 11px; }
.compare-row > span { color: #667d5b; }
.compare-row > strong { color: #3e6032; font-size: 13px; font-weight: 550; text-align: right; }
.compare-row small { display: block; margin-top: 4px; font-size: 12px; }
.compare-notes { margin: 23px 0; }
.compare-notes h3 { font-size: 13px; font-weight: 600; margin-bottom: 8px; }
.version-card .project-actions { margin-top: 12px; padding-top: 12px; }
.version-card .project-actions .btn:not(.icon) { flex: 0 1 auto; }
.help-steps { display: grid; gap: 24px; }
.help-steps > div { display: flex; gap: 17px; align-items: flex-start; }
.help-steps > div > span { display: grid; place-items: center; flex: 0 0 35px; width: 35px; height: 35px; border: 1px solid #d9e3cc; border-radius: 50%; background: #edf4e3; color: #627d50; font-size: 12px; }
.help-steps h3 { margin: 3px 0 7px; font-size: 16px; font-weight: 550; }
.help-steps p { color: #6d7f62; font-size: 13px; line-height: 1.8; }
.export-option { text-decoration: none; }
.export-option.danger strong { color: var(--danger); }
.hero-copy > p, .start-card p, .section-heading p, .project-card-body > p, .project-meta, .hero-proof, .canvas-heading p, .content-page > p, .page-heading > p, .compare-card p, .compare-card li, .brief-paper p, .brief-paper li { color: #65765f; }
.help-note, .source-note, .field small, .furniture-card small, .room-row-copy small, .room-area, .metric > span, .choice-card small, .choice-card p, .wizard-heading p, .wizard-summary p, .generated-card p, .comparison-note, .version-card p, .version-card small { color: #687b5e; }

/* A layout that stays useful from an expansive desktop to a phone. */
@media (min-width: 1600px) {
  .studio-workspace { grid-template-columns: 270px minmax(0, 1fr) 330px; }
  .studio-sidebar { padding-inline: 21px; }
  .inspector-body { padding-inline: 23px; }
  .canvas-heading { padding: 25px 32px 20px; }
  .canvas-bar { padding-inline: 25px; }
  .hero-scene { height: 510px; }
}

@media (max-width: 1280px) {
  .studio-header { grid-template-columns: minmax(205px, 1fr) auto minmax(190px, 1fr); padding-inline: 20px; gap: 12px; }
  .studio-nav button { padding-inline: 11px; }
  .header-actions .save-indicator { display: none; }
  .studio-workspace { grid-template-columns: 220px minmax(0, 1fr) 280px; }
  .studio-sidebar { padding-inline: 13px; }
  .inspector-body { padding-inline: 14px; }
  .inspector-tabs { padding-inline: 3px; }
  .inspector-tabs button { font-size: 12px; }
  .canvas-heading { padding-inline: 21px; }
  .canvas-heading h1 { font-size: 25px; }
  .canvas-bar { padding-inline: 13px; gap: 8px; }
  .canvas-bottom { padding-inline: 13px; }
  .canvas-tools { gap: 3px; }
  .welcome-page { padding: 35px 30px 40px; }
  .welcome-hero { gap: 30px; }
  .hero-scene { height: 440px; }
  .hero-copy h1 { font-size: 49px; }
  .project-card-body { padding-inline: 17px; }
  .project-name { font-size: 23px; }
  .content-page { padding-inline: 27px; }
  .brief-layout { grid-template-columns: minmax(300px, 380px) minmax(0, 1fr); gap: 20px; }
  .brief-form, .brief-preview { padding: 21px; }
}

@media (max-width: 1100px) {
  .studio-workspace { grid-template-columns: 230px minmax(0, 1fr); height: auto; min-height: 0; overflow: visible; }
  .studio-sidebar { overflow: visible; }
  .studio-canvas { min-height: 730px; }
  .studio-inspector { grid-column: 1 / -1; border-left: 0; border-top: 1px solid var(--line); overflow: visible; }
  .inspector-tabs { padding: 7px 20px; }
  .inspector-tabs button { min-height: 47px; flex-direction: row; gap: 7px; }
  .inspector-body { overflow: visible; padding: 25px; }
  .inspector-body .furniture-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .inspector-body .material-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .inspector-body .field-row { max-width: 600px; }
  .inspector-body .opening-list { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .selected-card { max-width: 650px; }
  .welcome-hero { grid-template-columns: minmax(300px, .9fr) minmax(0, 1fr); gap: 25px; }
  .hero-copy h1 { font-size: 44px; }
  .hero-copy > p { font-size: 14px; }
  .hero-scene { height: 410px; }
  .hero-actions { gap: 8px; }
  .hero-actions .btn { padding-inline: 14px; font-size: 13px; }
  .start-card { padding: 20px; }
  .start-card p { padding-right: 15px; }
  .project-thumbnail { height: 185px; }
  .project-name { font-size: 21px; }
  .project-actions .btn { font-size: 12px; padding-inline: 10px; }
  .compare-grid { gap: 14px; }
  .compare-card { padding: 17px; }
  .compare-card h2 { font-size: 23px; }
  .compare-preview, .compare-plan, .compare-preview svg, .compare-plan svg, .compare-card > svg { height: 200px; }
  .generated-grid { gap: 11px; }
  .generated-card { padding: 13px; }
  .version-card { grid-template-columns: 115px minmax(0, 1fr); gap: 15px; }
  .version-card > svg, .version-preview { width: 115px; height: 95px; }
}

@media (max-width: 900px) and (min-width: 801px) {
  :root { --header-height: 122px; }
  .studio-header { grid-template-columns: minmax(0, 1fr) auto; gap: 9px 15px; }
  .studio-nav { grid-row: 2; grid-column: 1 / -1; justify-content: center; }
  .studio-nav button { flex: 1; }
}

@media (max-width: 800px) {
  :root { --header-height: 122px; }
  .studio-header { grid-template-columns: minmax(0, 1fr) auto; gap: 13px 8px; padding: 14px 18px 12px; }
  .brand { gap: 9px; }
  .brand-mark { width: 31px; height: 36px; flex-basis: 31px; }
  .brand-mark svg { width: 30px; height: 35px; }
  .brand-name { font-size: 12px; letter-spacing: .08em; }
  .brand-subtitle { font-size: 12px; letter-spacing: .035em; }
  .studio-nav { grid-row: 2; grid-column: 1 / -1; width: 100%; }
  .studio-nav button { flex: 1; font-size: 12px; padding: 8px 9px; }
  .header-actions { gap: 4px; }
  .header-actions .btn { min-height: 34px; padding: 7px 9px; font-size: 12px; }
  .header-actions .save-indicator, .header-actions .optional-label { display: none; }
  .welcome-page { padding: 27px 21px 34px; }
  .welcome-hero { grid-template-columns: minmax(0, 1fr); gap: 24px; margin-bottom: 32px; }
  .hero-copy { max-width: 620px; padding: 0; }
  .hero-copy .eyebrow { margin-bottom: 12px; }
  .hero-copy h1 { font-size: 46px; max-width: 550px; margin-bottom: 17px; }
  .hero-copy > p { font-size: 14px; max-width: 550px; }
  .hero-actions { margin-top: 22px; }
  .hero-proof { margin-top: 18px; gap: 9px 16px; }
  .hero-scene { height: 365px; border-radius: 16px; }
  .hero-scene-caption { left: 13px; right: 13px; bottom: 12px; padding: 10px 12px; }
  .section-heading { display: block; margin-bottom: 17px; }
  .section-heading h2 { font-size: 26px; }
  .section-heading p { margin-top: 7px; }
  .section-heading > .btn, .section-heading > .badge, .section-heading > .muted { margin-top: 12px; }
  .start-grid { grid-template-columns: minmax(0, 1fr); gap: 12px; margin-bottom: 30px; }
  .start-card { display: grid; grid-template-columns: 44px minmax(0, 1fr) 25px; column-gap: 14px; align-items: center; min-height: 125px; padding: 19px; }
  .start-icon { grid-column: 1; grid-row: 1 / 3; width: 43px; height: 43px; margin: 0; }
  .start-card > span:not(.start-icon):not(.arrow) { grid-column: 2; grid-row: 1 / 3; }
  .start-card h3 { grid-column: 2; grid-row: 1; font-size: 17px; margin: 0 0 6px; }
  .start-card p { grid-column: 2; grid-row: 2; padding: 0; max-width: none; font-size: 13px; line-height: 1.65; }
  .start-card > .arrow { position: static; grid-column: 3; grid-row: 1 / 3; width: 25px; height: 25px; }
  .project-gallery, .saved-gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 15px; margin-bottom: 30px; }
  .project-thumbnail { height: 200px; }
  .project-card-body { padding: 17px; }
  .project-name { font-size: 23px; }
  .project-actions { padding-top: 13px; margin-top: 15px; }
  .book-strip { align-items: flex-start; flex-direction: column; padding: 23px; gap: 17px; }
  .book-strip h3 { font-size: 24px; }
  .studio-workspace { grid-template-columns: minmax(0, 1fr); }
  .studio-sidebar { display: block; padding: 18px; border-right: 0; border-bottom: 1px solid var(--line); }
  .project-heading { margin-bottom: 12px; }
  .project-heading h2 { font-size: 23px; }
  .project-select { max-width: 450px; margin-top: 4px; }
  .sidebar-section { margin-top: 15px; padding-top: 15px; }
  .sidebar-section .section-heading { display: flex; margin-bottom: 10px; }
  .room-list { display: flex; overflow-x: auto; gap: 8px; padding: 2px 2px 10px; scroll-snap-type: x proximity; }
  .room-row { flex: 0 0 208px; scroll-snap-align: start; }
  .sidebar-actions { flex-direction: row; flex-wrap: wrap; padding-top: 10px; margin-top: 0; }
  .sidebar-actions .btn { width: auto; flex: 1; }
  .studio-canvas { min-height: 665px; }
  .canvas-heading { padding: 20px 18px 17px; }
  .canvas-heading h1 { font-size: 27px; }
  .canvas-heading-actions { gap: 4px; }
  .canvas-heading-actions .btn { min-height: 33px; padding: 7px 9px; font-size: 12px; }
  .canvas-bar { flex-wrap: wrap; padding: 10px 13px; }
  .canvas-tools { max-width: 100%; overflow-x: auto; padding: 2px 1px; }
  .canvas-stage, #drawing-inner, #drawing-inner > svg { min-height: 420px; }
  .canvas-bottom { padding-inline: 11px; }
  .metric { padding: 15px 10px 12px; }
  .metric strong { font-size: 22px; }
  .metric > span { font-size: 12px; }
  .canvas-hint { bottom: 12px; padding: 7px 10px; font-size: 12px; }
  .validation-summary { padding-inline: 16px; flex-wrap: wrap; }
  .inspector-tabs { position: sticky; top: 0; z-index: 5; padding: 6px; }
  .inspector-tabs button { flex-direction: column; min-height: 58px; gap: 5px; }
  .inspector-body { padding: 23px 20px; }
  .inspector-body .furniture-grid, .inspector-body .material-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .inspector-body .opening-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .inspector-body .field-row { max-width: none; }
  .selected-card { max-width: none; }
  .field input:not([type="checkbox"]):not([type="radio"]), .field select, .field textarea { font-size: 16px; }
  .content-page { padding: 28px 20px 35px; }
  .content-page > h1, .page-heading h1 { font-size: 33px; }
  .content-page > p, .page-heading > p { font-size: 13px; }
  .compare-grid { grid-template-columns: minmax(0, 1fr); gap: 18px; }
  .compare-card { padding: 21px; }
  .compare-card h2 { font-size: 26px; }
  .compare-preview, .compare-plan, .compare-preview svg, .compare-plan svg, .compare-card > svg { height: 285px; }
  .brief-layout { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  .brief-form, .brief-preview { padding: 22px; }
  .brief-plan-preview { height: 310px; }
  .modal-backdrop { padding: 12px; }
  .modal { max-height: 94dvh; border-radius: 12px; }
  .modal-header { padding: 19px; }
  .modal-header h2, .modal-title { font-size: 25px; }
  .modal-body { padding: 20px 19px; }
  .modal-footer { padding: 15px 19px; }
  .wizard-stepper { gap: 4px; }
  .wizard-stepper > span, .wizard-stepper > div, .wizard-stepper > button { gap: 6px; font-size: 12px; padding-inline: 0; }
  .wizard-grid { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  .wizard-summary { position: static; padding: 18px; }
  .wizard-heading h2, .wizard-heading h3 { font-size: 27px; }
  .generated-grid { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .generated-card { padding: 18px; }
  .generated-card > svg, .generated-card .generated-preview > svg { height: 265px; }
  .version-card { grid-template-columns: 110px minmax(0, 1fr); gap: 14px; padding: 13px; }
  .version-card > svg, .version-preview { width: 110px; height: 95px; }
  .version-actions { grid-column: 1 / -1; padding-top: 11px; border-top: 1px solid #e1ebd4; }
  .version-actions .btn { flex: 1; }
  .studio-footer { flex-direction: column; gap: 6px; padding-inline: 20px; }
}

@media (max-width: 540px) {
  .studio-header { padding-inline: 13px; }
  .brand { gap: 7px; }
  .brand-name { font-size: 12px; letter-spacing: .045em; }
  .brand-subtitle { font-size: 12px; letter-spacing: 0; }
  .brand-mark { width: 28px; flex-basis: 28px; }
  .header-actions .btn .button-label { display: none; }
  .header-actions .btn { padding-inline: 8px; }
  .studio-nav { gap: 1px; }
  .studio-nav button { padding-inline: 7px; font-size: 12px; }
  .welcome-page { padding: 25px 18px 30px; }
  .hero-copy h1 { font-size: 41px; }
  .hero-copy .eyebrow { max-width: 290px; }
  .hero-scene { height: 330px; }
  .hero-scene-caption { display: block; font-size: 12px; padding: 9px 11px; }
  .hero-scene-caption > div { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 3px 10px; margin-top: 7px; text-align: left; }
  .hero-scene-caption > div > span { margin-top: 0; }
  .hero-scene-caption .badge { font-size: 12px; }
  .hero-actions .btn { flex: 1 0 auto; }
  .hero-proof { gap: 8px 13px; }
  .start-card { grid-template-columns: 40px minmax(0, 1fr) 21px; column-gap: 11px; padding: 17px; }
  .start-icon { width: 39px; height: 39px; }
  .start-card h3 { font-size: 16px; }
  .project-gallery, .saved-gallery { grid-template-columns: minmax(0, 1fr); gap: 18px; }
  .project-thumbnail { height: 235px; }
  .project-name { font-size: 25px; }
  .project-card-body { padding: 20px; }
  .canvas-heading { display: block; }
  .canvas-heading h1 { font-size: 26px; }
  .canvas-heading-actions { justify-content: flex-start; margin-top: 12px; }
  .canvas-bar { gap: 8px; }
  .canvas-tools { gap: 3px; }
  .canvas-tools .btn.small { padding-inline: 7px; }
  .canvas-bottom { padding-inline: 5px; }
  .metric { padding-inline: 9px; }
  .metric strong { font-size: 20px; }
  .metric > span { font-size: 12px; line-height: 1.35; }
  .inspector-body .furniture-grid, .inspector-body .material-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .inspector-body .opening-list { grid-template-columns: minmax(0, 1fr); }
  .option-grid { grid-template-columns: minmax(0, 1fr); }
  .wizard-stepper { grid-auto-flow: row; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 5px 12px; padding-bottom: 14px; }
  .wizard-stepper > span, .wizard-stepper > div, .wizard-stepper > button { padding-block: 4px; }
  .modal-footer { flex-wrap: wrap; gap: 8px; }
  .modal-footer .btn { flex: 1 0 auto; }
  .modal-footer .btn:first-child:not(:last-child) { margin-right: 0; }
  .brief-form, .brief-preview { padding: 19px; }
  .brief-paper h2 { font-size: 27px; }
  .brief-plan-preview { height: 270px; }
  .priority-grid { grid-template-columns: minmax(0, 1fr); gap: 5px; }
  .compare-preview, .compare-plan, .compare-preview svg, .compare-plan svg, .compare-card > svg { height: 250px; }
}

@media (max-width: 380px) {
  .brand-mark { display: none; }
  .brand > span:last-child { min-width: 0; }
  .brand-subtitle { max-width: 130px; }
  .studio-nav button { padding-inline: 4px; }
  .hero-actions { align-items: stretch; flex-direction: column; }
  .hero-copy h1 { font-size: 38px; }
  .version-card { grid-template-columns: 80px minmax(0, 1fr); gap: 10px; }
  .version-preview { width: 80px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
  .start-card:hover { transform: none; }
}

@page { size: letter; margin: .5in; }
@media print {
  html, body { height: auto; min-height: 0; overflow: visible !important; background: #fff !important; color: #183d3d; font-family: Arial, sans-serif; font-size: 10pt; }
  body > :not(#print-area), .screen-only, .modal-backdrop, .toast { display: none !important; }
  #print-area, .print-only { display: block !important; }
  #print-area { width: 100%; padding: 0; margin: 0; background: white; }
  #print-area * { print-color-adjust: exact; -webkit-print-color-adjust: exact; }
  #print-area h1 { font-family: Georgia, serif; font-size: 23pt; font-weight: 400; line-height: 1.2; letter-spacing: -.025em; margin: 12px 0 7px; }
  #print-area > p { color: #738466; font-size: 9pt; line-height: 1.6; }
  .print-header { display: flex; justify-content: space-between; align-items: flex-start; gap: 20px; border-bottom: 2px solid #264d3c; padding-bottom: 11px; margin-bottom: 13px; font-size: 8pt; color: #687f58; }
  .print-plan, .print-preview { width: 100%; margin: 13px 0 16px; break-inside: avoid; }
  .print-plan svg, .print-preview svg, .print-plan img, .print-preview img { width: 100%; height: auto; max-height: 4.5in; object-fit: contain; display: block; }
  .print-section { margin-top: 17px; break-inside: avoid; }
  .print-section h2, .print-section h3 { font-size: 10pt; padding-bottom: 5px; margin-bottom: 7px; border-bottom: 1px solid #dce7ce; }
  .print-section p, .print-section li { font-size: 9pt; line-height: 1.6; color: #506a40; overflow-wrap: anywhere; }
  .print-section ul { padding-left: 16px; margin-top: 6px; }
  .print-columns { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
  .print-table { width: 100%; border-collapse: collapse; font-size: 9pt; margin: 10px 0 15px; }
  .print-table th, .print-table td { padding: 7px 8px; border-bottom: 1px solid #dce7ce; text-align: left; vertical-align: top; }
  .print-table th { font-size: 8pt; font-weight: 550; background: #edf4e1; color: #698453; }
  .print-note, #print-area .source-note { font-size: 8pt; color: #83956e; line-height: 1.6; }
  .print-footer { padding-top: 9px; margin-top: 18px; border-top: 1px solid #dce7ce; font-size: 8pt; color: #83956e; line-height: 1.6; }
  a { color: inherit; text-decoration: none; }
}
