:root {
  --ink: #18212a;
  --muted: #64717e;
  --line: #dce2e8;
  --paper: #f7f9fb;
  --panel: #ffffff;
  --accent: #c74f2f;
  --accent-dark: #8c351e;
  --steel: #2e4d5f;
  --green: #62715a;
  --brand-surface: #f4fbfd;
  --shadow: 0 18px 50px rgba(21, 34, 48, .12);
  --facade-color: #b8503b;
  --frame-color: #25313c;
  --roof-color: #384653;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    radial-gradient(circle at 12% 0%, rgba(233, 138, 42, .08), transparent 34%),
    linear-gradient(135deg, rgba(28, 44, 77, .08), rgba(233, 138, 42, .04)),
    var(--paper);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.app-boot-overlay {
  position: fixed;
  inset: 0;
  z-index: 90000;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(247, 249, 251, .28);
  backdrop-filter: blur(1px);
  opacity: 1;
  visibility: visible;
  transition: opacity .28s ease, visibility 0s linear 0s;
}

.app-boot-card {
  display: grid;
  min-width: min(320px, calc(100vw - 40px));
  gap: 7px;
  justify-items: center;
  padding: 18px 22px;
  border: 1px solid rgba(255, 255, 255, .84);
  border-radius: 8px;
  color: var(--ink);
  background: rgba(255, 255, 255, .9);
  box-shadow: 0 18px 54px rgba(20, 35, 50, .16);
  text-align: center;
}

.app-boot-card strong {
  font-size: 15px;
}

.app-boot-card > span:last-child {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.app-boot-spinner {
  width: 30px;
  height: 30px;
  border: 3px solid rgba(24, 33, 42, .14);
  border-top-color: var(--accent);
  border-radius: 999px;
  animation: bta-spin .85s linear infinite;
}

body.is-app-booting {
  overflow: hidden;
}

body.is-app-booting .configurator {
  opacity: .46;
  filter: saturate(.74) blur(.7px);
  pointer-events: none;
}

body.is-app-booting .loading-badge {
  display: none !important;
}

body:not(.is-app-booting) .app-boot-overlay {
  opacity: 0;
  visibility: hidden;
  transition: opacity .28s ease, visibility 0s linear .28s;
}

.configurator {
  transition: opacity .28s ease, filter .28s ease;
}

@media (prefers-reduced-motion: reduce) {
  .app-boot-overlay,
  .configurator {
    transition: none;
  }

  .app-boot-spinner {
    animation-duration: 1.5s;
  }
}

button,
input,
select {
  font: inherit;
}

.app-shell {
  min-height: 100vh;
  padding: 18px;
}

body.is-embedded .app-shell {
  min-height: 0;
}

.mobile-experience-modal {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: grid;
  place-items: center;
  padding: 22px;
  background: rgba(24, 33, 42, .48);
  backdrop-filter: blur(10px);
  opacity: 0;
  pointer-events: none;
  transition: opacity .22s ease;
}

.mobile-experience-modal.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.mobile-experience-card {
  position: relative;
  width: min(100%, 560px);
  padding: clamp(28px, 7vw, 48px);
  border: 1px solid color-mix(in srgb, var(--steel) 16%, #fff);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .98), rgba(247, 250, 252, .98)),
    #fff;
  box-shadow: 0 28px 80px rgba(12, 24, 38, .28);
  color: var(--ink);
  text-align: left;
  transform: translateY(10px) scale(.98);
  transition: transform .22s ease;
}

.mobile-experience-modal.is-visible .mobile-experience-card {
  transform: translateY(0) scale(1);
}

.mobile-experience-close {
  position: absolute;
  top: 16px;
  right: 16px;
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  font-size: 38px;
  line-height: 1;
}

.mobile-experience-close:hover {
  background: color-mix(in srgb, var(--steel) 8%, #fff);
}

.mobile-experience-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 0 56px 24px 0;
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.mobile-experience-mark {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border-radius: 8px;
  background: var(--steel);
  color: #fff;
  box-shadow: inset 4px 0 0 var(--accent);
  font-weight: 900;
}

.mobile-experience-card h2 {
  max-width: 13ch;
  margin: 0;
  color: var(--steel);
  font-size: clamp(30px, 7.4vw, 46px);
  line-height: .98;
  letter-spacing: 0;
}

.mobile-experience-card p {
  margin: 22px 0 30px;
  color: #263241;
  font-size: clamp(18px, 4.6vw, 25px);
  line-height: 1.42;
}

.mobile-experience-action {
  display: inline-flex;
  min-width: 136px;
  min-height: 56px;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  box-shadow: 0 14px 30px color-mix(in srgb, var(--accent) 28%, transparent);
  cursor: pointer;
  font-size: 18px;
  font-weight: 900;
}

.mobile-experience-action:hover {
  background: color-mix(in srgb, var(--accent) 88%, #000);
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  max-width: 1840px;
  margin: 0 auto 18px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, .86);
  backdrop-filter: blur(18px);
}

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

.brand-mark {
  position: relative;
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  color: #fff;
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--accent) 92%, #fff), var(--steel));
  border-radius: 6px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .28);
  font-weight: 800;
  letter-spacing: 0;
  overflow: hidden;
}

.brand-logo {
  display: block;
  width: clamp(174px, 16vw, 260px);
  height: 58px;
  object-fit: contain;
  object-position: left center;
}

.brand-mark::before,
.brand-mark::after {
  position: absolute;
  content: "";
  opacity: .34;
  pointer-events: none;
}

.brand-mark::before {
  left: 7px;
  bottom: 7px;
  width: 24px;
  height: 20px;
  background:
    linear-gradient(var(--brand-surface), var(--brand-surface)) 0 0 / 10px 8px no-repeat,
    linear-gradient(var(--brand-surface), var(--brand-surface)) 12px 0 / 10px 8px no-repeat,
    linear-gradient(var(--brand-surface), var(--brand-surface)) 0 10px / 10px 8px no-repeat,
    linear-gradient(var(--brand-surface), var(--brand-surface)) 12px 10px / 10px 8px no-repeat;
}

.brand-mark::after {
  top: 8px;
  right: 7px;
  width: 3px;
  height: 26px;
  border-radius: 999px;
  background: #fff;
  transform: rotate(-22deg);
}

.brand small,
.eyebrow,
.choice-card small,
.select-row small,
.toggle-row small,
.summary-band span,
.notes p,
.quote-card dt {
  color: var(--muted);
}

.brand strong,
.brand small {
  display: block;
}

.step-nav,
.view-toggle,
.segmented {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 4px;
  border: 1px solid color-mix(in srgb, var(--steel) 20%, var(--line));
  border-radius: 8px;
  background: color-mix(in srgb, var(--steel) 8%, #fff);
}

.step-link,
.view-toggle label,
.segmented label {
  min-height: 38px;
  padding: 9px 12px;
  border: 0;
  border-radius: 6px;
  color: var(--muted);
  background: transparent;
  cursor: pointer;
  white-space: nowrap;
}

.step-link.is-active,
.view-toggle label:has(input:checked),
.segmented label:has(input:checked) {
  color: #fff;
  background: var(--steel);
  box-shadow: 0 4px 14px rgba(28, 44, 77, .18);
}

.view-toggle input,
.segmented input,
.choice-card input,
.swatch-option input {
  position: absolute;
  inline-size: 1px;
  block-size: 1px;
  opacity: 0;
}

body.is-model-step .view-toggle {
  display: none;
}

body.is-model-step #expandView {
  display: none !important;
}

body.is-model-step .scene-hud {
  display: none;
}

.configurator {
  display: grid;
  grid-template-columns: minmax(320px, 410px) minmax(640px, 1fr);
  gap: 18px;
  max-width: 1840px;
  margin: 0 auto;
}

body:not(.is-model-step) .configurator {
  grid-template-columns: minmax(230px, 300px) minmax(760px, 1fr);
}

body.is-build-step .configurator,
body.is-customize-step .configurator {
  grid-template-columns: 1fr;
}

body.is-build-step .preview-area,
body.is-customize-step .preview-area {
  grid-column: 1;
  grid-row: 1;
}

body.is-build-step .control-panel,
body.is-customize-step .control-panel {
  grid-column: 1;
  grid-row: 2;
  min-height: 0;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

body.is-build-step .panel-head,
body.is-build-step .steps,
body.is-customize-step .panel-head,
body.is-customize-step .steps {
  display: none;
}

body:not(.is-model-step) .variant-picker {
  display: none;
}

body.is-build-step .preview-area > .variant-picker {
  display: grid;
}

.control-panel,
.quote-card,
.notes {
  border: 1px solid color-mix(in srgb, var(--steel) 16%, var(--line));
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.control-panel {
  display: flex;
  min-height: calc(100vh - 112px);
  flex-direction: column;
  padding: 22px;
}

body.is-embedded .control-panel {
  min-height: 0;
}

.panel-head h1,
.preview-toolbar h2,
.quote-card h2 {
  margin: 0;
  letter-spacing: 0;
}

.panel-head h1 {
  font-size: 22px;
  line-height: 1.1;
}

.panel-head p:last-child {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
}

.eyebrow {
  margin: 0 0 7px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.steps {
  flex: 1;
  padding: 18px 0;
}

.step-pane {
  display: none;
}

.step-pane.is-active {
  display: block;
}

.choice-grid {
  display: grid;
  gap: 12px;
}

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

.choice-card {
  display: grid;
  gap: 8px;
  min-height: 168px;
  padding: 12px;
  border: 1px solid color-mix(in srgb, var(--steel) 16%, var(--line));
  border-radius: 8px;
  cursor: pointer;
  background: #fff;
  transition: border-color .2s, transform .2s, box-shadow .2s;
}

.choice-card img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 6px;
  background: color-mix(in srgb, var(--steel) 12%, #fff);
}

.choice-card strong,
.quote-card h2,
.panel-head h1 {
  color: var(--steel);
  font-family: "Bebas Neue", "Arial Narrow", Impact, sans-serif;
  font-weight: 800;
  text-transform: uppercase;
}

.choice-card strong {
  font-size: 17px;
  line-height: 1;
}

.choice-card small {
  font-size: 12px;
  line-height: 1.35;
}

.choice-card:hover,
.choice-card.is-selected,
.swatch-option.is-selected {
  border-color: var(--accent);
  box-shadow: 0 12px 30px rgba(28, 44, 77, .13);
}

.choice-card.is-selected {
  box-shadow: inset 0 -4px 0 var(--accent), 0 12px 30px rgba(28, 44, 77, .13);
}

.choice-card:hover {
  transform: translateY(-2px);
}

.choice-visual {
  position: relative;
  display: block;
  height: 74px;
  border-radius: 6px;
  background: linear-gradient(#dbe8ef, #f6fafc);
  overflow: hidden;
}

.choice-visual::before,
.choice-visual::after {
  position: absolute;
  content: "";
}

.choice-visual::before {
  left: 22%;
  right: 22%;
  bottom: 14px;
  height: 32px;
  background: var(--accent);
}

.choice-visual::after {
  left: 17%;
  right: 17%;
  bottom: 44px;
  border-left: 36px solid transparent;
  border-right: 36px solid transparent;
  border-bottom: 25px solid var(--steel);
}

.duplex::before {
  left: 12%;
  right: 12%;
}

.duplex::after {
  left: 10%;
  right: 10%;
}

.shed::before {
  left: 12%;
  right: 12%;
  height: 40px;
  background: #8f9ca8;
}

.shed::after {
  border-bottom-color: #415260;
}

.cabin::before {
  background: var(--green);
}

.cabin::after {
  border-bottom-color: #47513f;
}

.field-stack {
  display: grid;
  gap: 16px;
}

.variant-picker {
  display: grid;
  gap: 12px;
}

.option-head {
  display: grid;
  gap: 4px;
}

.option-head strong {
  font-size: 16px;
}

.option-head small,
.option-note {
  color: var(--muted);
  line-height: 1.45;
}

.option-note {
  margin: 0;
}

.config-variant-controls {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.config-variant-controls button {
  --tile-accent: var(--accent);
  --tile-bg: #fff7f3;
  display: grid;
  align-content: start;
  gap: 7px;
  min-height: 128px;
  padding: 13px 14px;
  border: 1px solid color-mix(in srgb, var(--tile-accent) 24%, var(--line));
  border-radius: 8px;
  color: var(--ink);
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--tile-accent) 16%, #fff), var(--tile-bg) 58%, #fff);
  cursor: pointer;
  text-align: left;
  position: relative;
  overflow: hidden;
  transition: border-color .2s, box-shadow .2s, transform .2s;
}

.config-variant-controls button::before {
  content: "";
  width: 34px;
  height: 6px;
  border-radius: 999px;
  background: var(--tile-accent);
}

.config-variant-controls button:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 28px rgba(20, 35, 50, .1);
}

.config-variant-controls button.is-active {
  border-color: var(--accent);
  box-shadow: 0 14px 36px rgba(199, 79, 47, .18);
}

.config-variant-controls button.variant-tile-0 {
  --tile-accent: #b78f62;
  --tile-bg: #fbf3e8;
}

.config-variant-controls button.variant-tile-1 {
  --tile-accent: #6f7f72;
  --tile-bg: #eef4ef;
}

.config-variant-controls button.variant-tile-2 {
  --tile-accent: #4f6170;
  --tile-bg: #edf3f6;
}

.config-variant-controls button.variant-tile-3 {
  --tile-accent: #c6b37a;
  --tile-bg: #fbf7e8;
}

.config-variant-controls button.variant-tile-4 {
  --tile-accent: #b8503b;
  --tile-bg: #fbefec;
}

.config-variant-controls button.variant-tile-5 {
  --tile-accent: #7d3f32;
  --tile-bg: #f7efed;
}

.config-variant-controls button strong {
  font-size: 15px;
}

.config-variant-controls button span {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

.range-row,
.select-row,
.toggle-row {
  display: grid;
  gap: 12px;
  padding: 15px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.range-row > span,
.select-row > span,
.toggle-row {
  align-items: center;
}

.range-row > span,
.select-row > span {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

.range-row small,
.select-row small {
  display: block;
}

input[type="range"] {
  width: 100%;
  accent-color: var(--accent);
}

.select-row select {
  width: 100%;
  min-height: 42px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
}

fieldset {
  margin: 0 0 18px;
  padding: 0;
  border: 0;
}

legend {
  margin-bottom: 10px;
  font-weight: 800;
}

.swatch-row {
  display: grid;
  gap: 8px;
}

.swatch-option,
.toggle-row {
  display: flex;
  gap: 12px;
  cursor: pointer;
}

.swatch-option {
  align-items: center;
  min-height: 46px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.swatch-option span {
  width: 28px;
  height: 28px;
  border: 1px solid rgba(0, 0, 0, .12);
  border-radius: 50%;
  background: var(--swatch);
}

.toggle-row input {
  width: 20px;
  height: 20px;
  margin-top: 2px;
  accent-color: var(--accent);
}

.panel-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

body.is-model-step .panel-actions {
  grid-template-columns: 1fr;
}

.preview-footer {
  display: grid;
  grid-template-columns: minmax(280px, 460px) minmax(340px, 520px);
  justify-content: space-between;
  align-items: stretch;
  gap: 10px;
  margin-top: -6px;
}

.preview-footer > .panel-actions {
  grid-column: 1;
  width: 100%;
  align-self: stretch;
}

.preview-footer > .summary-band {
  grid-column: 2;
}

.preview-footer > .step-nav {
  grid-column: 1;
  align-self: stretch;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  width: 100%;
}

.preview-footer > .footer-step-nav {
  display: none;
}

.preview-footer .step-link,
.preview-footer .primary-button,
.preview-footer .ghost-button,
.summary-band article {
  min-height: 70px;
}

.primary-button,
.ghost-button {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
}

.primary-button {
  border: 1px solid var(--accent);
  color: var(--steel);
  background: var(--accent);
  box-shadow: 0 10px 24px rgba(233, 138, 42, .22);
}

.primary-button:hover {
  color: #fff;
  background: var(--accent-dark);
}

.ghost-button {
  border: 1px solid color-mix(in srgb, var(--steel) 20%, var(--line));
  color: var(--ink);
  background: #fff;
}

.primary-button:disabled,
.ghost-button:disabled {
  cursor: not-allowed;
  opacity: .45;
}

.preview-area {
  display: flex;
  min-height: calc(100vh - 112px);
  flex-direction: column;
  gap: 14px;
}

body.is-embedded .preview-area {
  min-height: 0;
}

.preview-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 66px;
  padding: 11px 16px;
  border: 1px solid color-mix(in srgb, var(--steel) 70%, #fff);
  border-radius: 8px;
  background:
    linear-gradient(135deg, var(--brand-surface), color-mix(in srgb, var(--brand-surface) 86%, #000));
  color: #fff;
  box-shadow: 0 18px 44px rgba(28, 44, 77, .18);
}

.preview-titlebar {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 18px;
}

.client-identity {
  min-width: min(320px, 38vw);
  position: relative;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: transparent;
  box-shadow: none;
}

.client-identity.has-logo .brand-copy {
  display: none;
}

.brand-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.client-identity strong {
  color: #fff;
  font-family: "Bebas Neue", "Arial Narrow", Impact, sans-serif;
  font-size: 19px;
  font-weight: 800;
  letter-spacing: .02em;
  text-transform: uppercase;
}

.client-identity small {
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.preview-title {
  min-width: 0;
  padding-left: 18px;
  border-left: 1px solid rgba(255, 255, 255, .2);
}

.preview-title .eyebrow {
  color: color-mix(in srgb, var(--accent) 88%, #fff);
}

.preview-toolbar h2 {
  color: #fff;
  font-family: "Bebas Neue", "Arial Narrow", Impact, sans-serif;
  font-size: clamp(22px, 2.3vw, 32px);
  font-weight: 800;
  line-height: .95;
  text-transform: uppercase;
}

.preview-toolbar .view-toggle {
  border-color: rgba(255, 255, 255, .2);
  background: rgba(255, 255, 255, .08);
}

.preview-toolbar .view-toggle label {
  color: rgba(255, 255, 255, .76);
}

.preview-toolbar .view-toggle label:has(input:checked) {
  color: var(--steel);
  background: #fff;
}

.visual-stage {
  position: relative;
  flex: 1;
  min-height: 430px;
  border: 1px solid color-mix(in srgb, var(--steel) 20%, var(--line));
  border-radius: 8px;
  background:
    linear-gradient(180deg, #dfeef7 0%, #f7fbfd 58%, #d4dfce 58%, #edf3e8 100%);
  box-shadow: var(--shadow);
  overflow: hidden;
  touch-action: none;
}

body.is-embedded .visual-stage {
  flex: none;
  height: clamp(460px, 42vw, 640px);
  min-height: 0;
}

body.is-embedded.is-build-step .visual-stage,
body.is-embedded.is-customize-step .visual-stage {
  height: clamp(540px, 48vw, 700px);
}

.model-config-overlay {
  position: absolute;
  left: 14px;
  top: 14px;
  z-index: 4;
  display: grid;
  width: min(286px, calc(100% - 28px));
  gap: 8px;
  padding: 8px;
  border: 1px solid rgba(220, 226, 232, .9);
  border-radius: 10px;
  background: rgba(250, 252, 253, .94);
  box-shadow: 0 20px 54px rgba(20, 35, 50, .18);
  backdrop-filter: blur(18px);
  pointer-events: auto;
}

.model-config-overlay[hidden] {
  display: none !important;
}

.model-config-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: -8px -8px 0;
  padding: 9px 10px;
  border-bottom: 1px solid rgba(220, 226, 232, .78);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, .98), rgba(239, 246, 249, .96));
}

.model-config-mark {
  display: grid;
  width: 30px;
  height: 30px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 8px;
  color: #fff;
  background: linear-gradient(135deg, #174b6d, #c74f2f);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .28), 0 8px 18px rgba(20, 35, 50, .12);
  font-size: 14px;
  font-weight: 950;
}

.model-config-head strong {
  display: block;
  color: var(--ink);
  font-size: 15px;
  line-height: 1.15;
}

.model-config-head small {
  display: block;
  color: #728392;
  font-size: 10px;
  font-weight: 850;
  line-height: 1.2;
}

.model-config-help {
  margin: 0;
  padding: 8px 10px;
  border: 1px solid rgba(46, 77, 95, .1);
  border-radius: 8px;
  color: #526372;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, .86), rgba(239, 246, 249, .76));
  font-size: 11px;
  font-weight: 850;
  line-height: 1.35;
}

.model-config-overlay details {
  --overlay-accent: #365f7c;
  --overlay-dark: #183b55;
  border: 1px solid color-mix(in srgb, var(--overlay-accent) 26%, rgba(220, 226, 232, .95));
  border-radius: 8px;
  background:
    linear-gradient(90deg, color-mix(in srgb, var(--overlay-accent) 12%, transparent), transparent 34%),
    rgba(255, 255, 255, .9);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .95), 0 8px 22px rgba(20, 35, 50, .06);
  overflow: hidden;
}

.model-config-overlay details:nth-of-type(2) {
  --overlay-accent: #b66a3c;
  --overlay-dark: #7a3c1f;
}

.model-config-overlay details:nth-of-type(3) {
  --overlay-accent: #c59a2e;
  --overlay-dark: #7a5a11;
}

.model-config-overlay summary {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  padding: 8px 10px;
  cursor: pointer;
  font-weight: 900;
  list-style: none;
}

.model-config-overlay summary::-webkit-details-marker {
  display: none;
}

.model-config-overlay summary::before {
  display: inline-grid;
  width: 22px;
  height: 22px;
  place-items: center;
  border-radius: 6px;
  color: #fff;
  background:
    radial-gradient(circle at 30% 22%, rgba(255, 255, 255, .34), transparent 34%),
    linear-gradient(135deg, var(--overlay-accent), var(--overlay-dark));
  box-shadow: 0 7px 14px color-mix(in srgb, var(--overlay-accent) 24%, transparent);
  content: "✓";
  font-size: 11px;
  line-height: 1;
}

.model-config-overlay details:nth-of-type(2) summary::before {
  content: "▦";
}

.model-config-overlay details:nth-of-type(3) summary::before {
  content: "⌂";
}

.model-config-overlay summary::after {
  width: 8px;
  height: 8px;
  margin-left: auto;
  border-right: 2px solid #71808d;
  border-bottom: 2px solid #71808d;
  content: "";
  transform: rotate(45deg);
  transition: transform .18s ease;
}

.model-config-overlay details[open] summary::after {
  transform: rotate(225deg);
}

.model-config-overlay label {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  margin: 0 9px 8px;
  padding: 7px 9px;
  border: 1px solid rgba(220, 226, 232, .86);
  border-radius: 7px;
  color: var(--ink);
  background: rgba(255, 255, 255, .72);
  box-shadow: 0 6px 15px rgba(20, 35, 50, .06);
  cursor: pointer;
  font-size: 13px;
  font-weight: 850;
  transition: background .16s ease, border-color .16s ease, box-shadow .16s ease, transform .16s ease;
}

.model-config-overlay summary + label {
  margin-top: 0;
}

.model-config-overlay label:hover {
  border-color: color-mix(in srgb, var(--overlay-accent) 34%, rgba(220, 226, 232, .86));
  background: rgba(255, 255, 255, .94);
  transform: translateY(-1px);
}

.model-config-overlay label:has(input:checked) {
  border-color: color-mix(in srgb, var(--overlay-accent) 42%, rgba(220, 226, 232, .86));
  background: #fff;
  box-shadow: 0 8px 18px rgba(20, 35, 50, .12);
}

.model-config-overlay input {
  accent-color: var(--accent);
  width: 16px;
  height: 16px;
  margin: 0;
}

.step3-config-panel {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  z-index: 5;
  display: flex;
  flex-direction: column;
  width: clamp(300px, 24vw, 370px);
  max-height: none;
  gap: 0;
  padding: 0;
  border: 0;
  border-right: 1px solid color-mix(in srgb, var(--steel) 18%, rgba(220, 226, 232, .92));
  border-radius: 0 8px 8px 0;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .98), rgba(249, 251, 253, .96));
  box-shadow: 12px 0 34px rgba(28, 44, 77, .14);
  overflow: hidden;
  overscroll-behavior: contain;
  pointer-events: auto;
  transform-origin: top left;
  animation: step3PanelIn .34s cubic-bezier(.2, .78, .22, 1) both;
  backdrop-filter: blur(18px);
  will-change: transform, opacity;
  scrollbar-color: rgba(28, 44, 77, .35) transparent;
  scrollbar-width: thin;
}

.step3-config-panel::-webkit-scrollbar {
  width: 7px;
}

.step3-config-panel::-webkit-scrollbar-thumb {
  border: 2px solid transparent;
  border-radius: 999px;
  background: rgba(28, 44, 77, .28);
  background-clip: padding-box;
}

.step3-config-panel.is-switching {
  scroll-behavior: smooth;
}

.step3-config-panel[hidden] {
  display: none !important;
}

.step3-panel-head {
  position: sticky;
  top: 0;
  z-index: 2;
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 12px 12px 10px;
  border-bottom: 1px solid color-mix(in srgb, var(--steel) 18%, rgba(220, 226, 232, .78));
  background:
    linear-gradient(135deg, #fff, color-mix(in srgb, var(--steel) 6%, #fff));
  backdrop-filter: blur(14px);
}

.step3-panel-head .eyebrow {
  margin-bottom: 0;
  color: var(--accent);
  font-size: 9px;
  letter-spacing: .08em;
}

.step3-panel-head strong {
  display: block;
  color: var(--steel);
  font-family: "Bebas Neue", "Arial Narrow", Impact, sans-serif;
  font-size: 17px;
  line-height: 1.15;
}

.step3-panel-head small {
  display: none;
  color: var(--muted);
  line-height: 1.4;
}

.step3-panel-title {
  display: flex;
  align-items: center;
  gap: 9px;
}

.step3-panel-title > div {
  min-width: 0;
}

.step3-collapse-button {
  display: grid;
  width: 30px;
  height: 30px;
  margin-left: auto;
  place-items: center;
  border: 1px solid rgba(46, 77, 95, .16);
  border-radius: 6px;
  background: #fff;
  box-shadow: 0 5px 12px rgba(20, 35, 50, .08);
  cursor: pointer;
}

.step3-collapse-button::before {
  width: 8px;
  height: 8px;
  border-left: 2px solid #526372;
  border-bottom: 2px solid #526372;
  content: "";
  transform: rotate(45deg);
  transition: transform .18s ease;
}

.step3-panel-mark {
  display: grid;
  width: 32px;
  height: 32px;
  flex: 0 0 auto;
  place-items: center;
  border: 1px solid rgba(46, 77, 95, .12);
  border-radius: 8px;
  color: #fff;
  background: linear-gradient(135deg, var(--steel), var(--accent));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .28), 0 8px 18px rgba(20, 35, 50, .12);
  font-size: 15px;
  font-weight: 950;
}

.step3-breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 5px;
  color: #667887;
  font-size: 9px;
  font-weight: 850;
}

.step3-breadcrumb strong {
  color: var(--steel);
  font-size: inherit;
}

.step3-panel-actions {
  display: flex;
  justify-content: flex-start;
}

.step3-reset-button {
  justify-self: start;
  min-height: 28px;
  padding: 0 9px;
  border: 1px solid rgba(46, 77, 95, .18);
  border-radius: 6px;
  color: #263b4a;
  background: #fff;
  box-shadow: 0 6px 16px rgba(20, 35, 50, .08);
  cursor: pointer;
  font-size: 12px;
  font-weight: 900;
  transition: background .18s ease, border-color .18s ease, transform .18s ease;
}

.step3-reset-button:hover {
  border-color: color-mix(in srgb, var(--accent) 44%, var(--line));
  background: color-mix(in srgb, var(--accent) 10%, #fff);
  transform: translateY(-1px);
}

.step3-reset-button[hidden] {
  display: none !important;
}

.step3-config-panel.is-collapsed {
  width: 112px;
  bottom: auto;
  max-height: calc(100% - 20px);
  overflow: hidden;
}

.step3-config-panel.is-collapsed .step3-panel-head {
  position: static;
  margin: 0;
}

.step3-config-panel.is-collapsed .step3-panel-title {
  justify-content: center;
}

.step3-config-panel.is-collapsed .step3-panel-title > div,
.step3-config-panel.is-collapsed .step3-breadcrumb,
.step3-config-panel.is-collapsed .step3-panel-head > small,
.step3-config-panel.is-collapsed .step3-panel-actions,
.step3-config-panel.is-collapsed .step3-category-chevron,
.step3-config-panel.is-collapsed .step3-category-title small,
.step3-config-panel.is-collapsed .step3-category-body {
  display: none;
}

.step3-config-panel.is-collapsed .step3-collapse-button {
  margin-left: 0;
}

.step3-config-panel.is-collapsed .step3-collapse-button::before {
  transform: rotate(225deg);
}

.step3-config-panel.is-collapsed .step3-category-list {
  gap: 6px;
  padding: 8px;
}

.step3-config-panel.is-collapsed .step3-category {
  max-height: 54px;
  background: rgba(255, 255, 255, .72);
}

.step3-config-panel.is-collapsed .step3-category-summary {
  display: grid;
  justify-items: center;
  min-height: 52px;
  gap: 4px;
  padding: 7px 4px;
}

.step3-config-panel.is-collapsed .step3-category-icon {
  width: 24px;
  height: 24px;
}

.step3-config-panel.is-collapsed .step3-category-title strong {
  max-width: 92px;
  font-size: 10px;
  line-height: 1.05;
  text-align: center;
}

.step3-category-list {
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 8px;
  min-height: 0;
  padding: 10px 12px 12px;
  overflow-y: auto;
  overscroll-behavior: contain;
  touch-action: pan-y;
  -webkit-overflow-scrolling: touch;
  scrollbar-color: rgba(28, 44, 77, .28) transparent;
  scrollbar-width: thin;
}

.step3-category-list::-webkit-scrollbar {
  width: 7px;
}

.step3-category-list::-webkit-scrollbar-thumb {
  border: 2px solid transparent;
  border-radius: 999px;
  background: rgba(28, 44, 77, .26);
  background-clip: padding-box;
}

.step3-category {
  --part-accent: var(--steel);
  --part-accent-dark: color-mix(in srgb, var(--steel) 82%, #000);
  --part-surface: rgba(234, 246, 253, .92);
  flex: 0 0 auto;
  max-height: 62px;
  border: 1px solid color-mix(in srgb, var(--part-accent) 26%, rgba(220, 226, 232, .95));
  border-radius: 8px;
  background:
    linear-gradient(90deg, color-mix(in srgb, var(--part-accent) 10%, transparent), transparent 38%),
    rgba(255, 255, 255, .9);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .95), 0 6px 18px rgba(20, 35, 50, .055);
  overflow: hidden;
  opacity: 1;
  transform: translateY(0);
  transition:
    max-height .3s cubic-bezier(.2, .78, .22, 1),
    opacity .22s ease,
    transform .24s ease,
    border-color .22s ease,
    box-shadow .22s ease,
    margin .3s ease;
}

.step3-category:nth-child(1) {
  --part-accent: var(--accent);
  --part-accent-dark: var(--accent-dark);
  --part-surface: #e8f1f7;
}

.step3-category:nth-child(2) {
  --part-accent: var(--steel);
  --part-accent-dark: #121d33;
  --part-surface: #f8eee7;
}

.step3-category:nth-child(3) {
  --part-accent: #334766;
  --part-accent-dark: var(--steel);
  --part-surface: #e7f4f1;
}

.step3-category:nth-child(4) {
  --part-accent: var(--accent);
  --part-accent-dark: var(--accent-dark);
  --part-surface: #eef5e8;
}

.step3-category:nth-child(5) {
  --part-accent: var(--steel);
  --part-accent-dark: #121d33;
  --part-surface: #fbf4dd;
}

.step3-category:nth-child(6) {
  --part-accent: #334766;
  --part-accent-dark: var(--steel);
  --part-surface: #e8f0f8;
}

.step3-category:nth-child(7) {
  --part-accent: var(--accent);
  --part-accent-dark: var(--accent-dark);
  --part-surface: #f1eaf5;
}

.step3-config-panel.is-filtered .step3-category.is-step3-inactive {
  opacity: 1;
  pointer-events: auto;
  transform: none;
}

.step3-config-panel.is-filtered .step3-category.is-step3-active {
  max-height: 920px;
  border-color: color-mix(in srgb, var(--part-accent) 48%, rgba(35, 135, 220, .36));
  background:
    linear-gradient(90deg, color-mix(in srgb, var(--part-accent) 16%, transparent), transparent 42%),
    rgba(255, 255, 255, .97);
  box-shadow: 0 12px 30px rgba(20, 35, 50, .13);
}

.step3-category.is-open {
  max-height: 920px;
}

.step3-config-panel.is-switching .step3-category.is-step3-active {
  animation: step3CategoryIn .28s cubic-bezier(.2, .78, .22, 1) both;
}

.step3-category-summary {
  display: grid;
  grid-template-columns: 5px 30px minmax(0, 1fr) 14px;
  align-items: center;
  gap: 8px;
  width: 100%;
  min-height: 48px;
  padding: 9px 10px;
  border: 0;
  color: inherit;
  background: transparent;
  cursor: pointer;
  font: inherit;
  font-weight: 900;
  text-align: left;
}

.step3-category-summary::before {
  width: 5px;
  align-self: stretch;
  border-radius: 999px;
  background: var(--part-accent);
  content: "";
}

.step3-category-icon {
  display: inline-grid;
  place-items: center;
  width: 30px;
  height: 30px;
  flex: 0 0 auto;
  border-radius: 5px;
  color: #fff;
  background:
    radial-gradient(circle at 30% 22%, rgba(255, 255, 255, .34), transparent 34%),
    linear-gradient(135deg, var(--part-accent), var(--part-accent-dark));
  box-shadow: 0 7px 14px color-mix(in srgb, var(--part-accent) 24%, transparent);
  font-size: 15px;
  font-weight: 950;
}

.step3-category-title {
  display: grid;
  min-width: 0;
  gap: 1px;
}

.step3-category-title strong {
  overflow: hidden;
  color: var(--steel);
  font-size: 13px;
  line-height: 1.1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.step3-category-title small {
  color: #798794;
  font-size: 9px;
  font-weight: 850;
  line-height: 1.1;
}

.step3-category-chevron {
  width: 8px;
  height: 8px;
  border-right: 2px solid #7a8793;
  border-bottom: 2px solid #7a8793;
  transform: rotate(45deg);
  transition: transform .18s ease;
}

.step3-category.is-open .step3-category-chevron {
  transform: rotate(225deg);
}

.step3-category-body {
  display: none;
}

.step3-category.is-open .step3-category-body {
  display: block;
}

.step3-category-body-inner {
  display: grid;
  gap: 10px;
  min-height: 0;
  overflow: hidden;
  padding: 0 10px 10px 53px;
  animation: step3OptionsIn .24s cubic-bezier(.2, .78, .22, 1) both;
}

.step3-option-row {
  display: grid;
  gap: 6px;
  padding-top: 2px;
}

.step3-option-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.step3-option-label > span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
}

.step3-option-label small {
  display: none;
  padding: 3px 6px;
  border-radius: 999px;
  color: var(--accent-dark);
  background: color-mix(in srgb, var(--accent) 12%, #fff);
  font-size: 9px;
  font-weight: 950;
  line-height: 1;
}

.step3-option-row.is-modified .step3-option-label small {
  display: inline-block;
}

.step3-option-buttons {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(82px, 1fr));
  gap: 5px;
  padding: 4px;
  border: 1px solid color-mix(in srgb, var(--steel) 14%, rgba(220, 226, 232, .86));
  border-radius: 8px;
  background: color-mix(in srgb, var(--steel) 7%, #fff);
}

.step3-option-buttons button {
  min-height: 32px;
  padding: 0 9px;
  border: 1px solid transparent;
  border-radius: 6px;
  color: var(--ink);
  background: transparent;
  cursor: pointer;
  font-size: 11px;
  font-weight: 850;
  transition: background .16s ease, border-color .16s ease, color .16s ease, transform .16s ease;
}

.step3-option-buttons button:hover {
  border-color: color-mix(in srgb, var(--steel) 18%, transparent);
  background: rgba(255, 255, 255, .74);
}

.step3-option-buttons button.is-original-option {
  color: #526372;
  font-weight: 900;
}

.step3-option-buttons button.is-active {
  color: var(--steel);
  border-color: color-mix(in srgb, var(--accent) 42%, #fff);
  background: #fff;
  box-shadow: inset 0 -3px 0 var(--accent), 0 6px 15px rgba(28, 44, 77, .12);
}

.step3-option-buttons button.is-original-option.is-active {
  color: var(--steel);
  border-color: color-mix(in srgb, var(--steel) 24%, #fff);
  background: linear-gradient(180deg, #fff, color-mix(in srgb, var(--steel) 5%, #fff));
}

.step3-category[data-step3-category="frames"].is-open,
.step3-config-panel.is-filtered .step3-category[data-step3-category="frames"].is-step3-active {
  max-height: 1680px;
  border-color: rgba(196, 218, 214, .34);
  background:
    radial-gradient(circle at 82% 8%, rgba(132, 169, 137, .18), transparent 35%),
    linear-gradient(145deg, rgba(38, 71, 72, .96), rgba(28, 51, 58, .97));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .13), 0 12px 30px rgba(9, 26, 32, .24);
}

.step3-category[data-step3-category="frames"] .step3-category-body-inner {
  padding-left: 10px;
}

.step3-category[data-step3-category="frames"] .step3-category-title strong {
  color: #f5f8f7;
}

.step3-category[data-step3-category="frames"] .step3-category-title small {
  color: rgba(235, 243, 241, .68);
}

.step3-category[data-step3-category="frames"] .step3-category-chevron {
  border-color: rgba(241, 247, 245, .72);
}

.step3-combined-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  padding: 3px;
  border: 1px solid rgba(224, 237, 234, .2);
  border-radius: 7px;
  background: rgba(9, 29, 35, .28);
}

.step3-combined-tabs button {
  min-height: 32px;
  border: 0;
  border-radius: 5px;
  color: rgba(239, 246, 244, .7);
  background: transparent;
  cursor: pointer;
  font-size: 11px;
  font-weight: 900;
}

.step3-combined-tabs button.is-active {
  color: #fff;
  background: rgba(255, 255, 255, .13);
  box-shadow: inset 0 -3px 0 var(--accent), 0 4px 12px rgba(9, 25, 31, .18);
}

.step3-combined-pane {
  display: grid;
  gap: 9px;
}

.step3-combined-pane[hidden] {
  display: none !important;
}

.step3-combined-color-grid,
.step3-combined-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
}

.step3-combined-pane[data-step3-combined-pane="doors"] {
  grid-template-columns: 1fr;
}

.step3-door-selector {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(150px, .95fr);
  gap: 10px;
}

.step3-door-hero {
  position: relative;
  min-height: 320px;
  overflow: hidden;
  border: 1px solid rgba(225, 237, 234, .26);
  border-radius: 8px;
  background: #d8d5ca;
  box-shadow: 0 10px 24px rgba(7, 22, 27, .2);
}

.step3-door-hero-variant {
  position: absolute;
  inset: 0;
  display: none;
  width: 100%;
  height: 100%;
  min-height: 320px;
  object-fit: cover;
  object-position: center 44%;
}

.step3-door-hero-variant.is-active {
  display: block;
}

.step3-door-hero-selection {
  position: absolute;
  left: 9px;
  right: 9px;
  bottom: 9px;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 9px;
  border: 1px solid rgba(255, 255, 255, .48);
  border-radius: 7px;
  color: #fff;
  background: rgba(13, 31, 35, .74);
  box-shadow: 0 5px 14px rgba(8, 20, 24, .24);
  backdrop-filter: blur(7px);
}

.step3-door-hero-selection > i {
  width: 24px;
  height: 24px;
  flex: 0 0 auto;
  border: 1px solid rgba(255, 255, 255, .7);
  border-radius: 5px;
  background: var(--selected-color, #383e42);
}

.step3-door-hero-selection > span {
  display: grid;
  min-width: 0;
  line-height: 1.08;
}

.step3-door-hero-selection b { font-size: 10px; }
.step3-door-hero-selection small { color: rgba(255, 255, 255, .75); font-size: 8px; }

.step3-door-type-list {
  display: grid;
  align-content: start;
  gap: 6px;
}

.step3-door-type-list > strong {
  color: #f6f9f8;
  font-size: 12px;
  font-weight: 950;
}

.step3-door-type-list > div {
  display: grid;
  gap: 5px;
}

.step3-door-type-option {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  min-height: 54px;
  padding: 4px;
  border: 2px solid transparent;
  border-radius: 7px;
  color: #f4f8f7;
  background: rgba(255, 255, 255, .08);
  cursor: pointer;
  text-align: left;
}

.step3-door-type-option:hover {
  background: rgba(255, 255, 255, .13);
}

.step3-door-type-option.is-active {
  border-color: var(--accent);
  background: rgba(255, 255, 255, .14);
  box-shadow: 0 5px 14px rgba(7, 22, 27, .22);
}

.step3-door-type-option > span {
  display: grid;
  min-width: 0;
  gap: 2px;
}

.step3-door-type-option strong {
  font-size: 10px;
  font-weight: 950;
}

.step3-door-type-option small {
  overflow: hidden;
  color: rgba(237, 245, 243, .66);
  font-size: 8px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.step3-door-type-thumb {
  width: 42px;
  height: 48px;
  border-radius: 4px;
  object-fit: cover;
  object-position: center 38%;
}

.step3-option-row[data-step3-option-row="facade.color"] .step3-option-buttons {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.step3-option-row[data-step3-option-row="facade.color"] .step3-option-buttons button[data-step3-value] {
  -webkit-appearance: none;
  appearance: none;
  align-items: end;
  min-height: 68px;
  padding: 8px;
  border: 2px solid transparent;
  color: #fff;
  background-color: #6c625a;
  background-image: linear-gradient(180deg, transparent 38%, rgba(13, 21, 24, .82) 100%), var(--step3-option-texture);
  background-clip: border-box;
  background-origin: border-box;
  background-position: center;
  background-size: cover;
  box-shadow: none;
  overflow: hidden;
  text-align: left;
  text-shadow: 0 1px 3px rgba(0, 0, 0, .78);
}

.step3-option-row[data-step3-option-row="facade.color"] .step3-option-buttons button[data-step3-value].is-active {
  border-color: var(--accent);
  background-image: linear-gradient(180deg, transparent 38%, rgba(13, 21, 24, .7) 100%), var(--step3-option-texture);
  box-shadow: inset 0 -3px 0 var(--accent), 0 5px 12px rgba(20, 35, 50, .18);
}

.step3-option-row[data-step3-option-row="facade.plinth"] .step3-option-buttons {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.step3-option-row[data-step3-option-row="facade.plinth"] .step3-option-buttons button {
  display: grid;
  min-height: 0;
  place-items: center;
  gap: 4px;
  padding: 3px 3px 6px;
  line-height: 1.05;
}

.step3-plinth-preview {
  display: block;
  width: 100%;
  aspect-ratio: .874 / 1;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .28);
  border-radius: 5px;
  background-color: #9e715a;
  background-image: url("./assets/ui/facade-plinth/plinth-options.png");
  background-repeat: no-repeat;
  background-size: 235.2% 256.8%;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .2);
}

.step3-plinth-preview.is-without-plinth {
  background-position: 10.1% 40.2%;
}

.step3-plinth-preview.has-plinth {
  background-position: 90.2% 40.2%;
}

.step3-option-default {
  display: block;
  color: inherit;
  font-size: 8px;
  font-weight: 500;
  opacity: .84;
}

.step3-option-row[data-step3-option-row="facade.color"] .step3-option-buttons button[data-step3-value],
.step3-option-row[data-step3-option-row="facade.color"] .step3-option-buttons button[data-step3-original="true"] {
  display: grid;
  grid-template-rows: auto auto;
  min-width: 0;
  min-height: 0;
  place-items: center;
  gap: 4px;
  padding: 3px 3px 5px;
  color: #fff;
  background: rgba(10, 28, 34, .42) !important;
  background-image: none !important;
  text-align: center;
  text-shadow: none;
}

.step3-facade-preview {
  display: block;
  width: 100%;
  aspect-ratio: 2.24 / 1;
  border: 1px solid rgba(255, 255, 255, .28);
  border-radius: 5px;
  background-image: url("./assets/ui/facade-stones/facade-options.png");
  background-repeat: no-repeat;
  background-size: 230% 643%;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .16);
}

.step3-facade-preview.is-original { background-position: 9.5% 12%; }
.step3-facade-preview.is-aalborg { background-position: 90.8% 12%; }
.step3-facade-preview.is-acera { background-position: 9.5% 36.3%; }
.step3-facade-preview.is-akita { background-position: 90.8% 36.3%; }
.step3-facade-preview.is-alaska { background-position: 9.5% 60.7%; }
.step3-facade-preview.is-castello-geel { background-position: 90.8% 60.7%; }
.step3-facade-preview.is-nevado-light { background-position: 9.5% 85.1%; }
.step3-facade-preview.is-wapper-rainbow-snowdust { background-position: 90.8% 85.1%; }

.step3-energy-intro {
  display: grid;
  grid-template-columns: minmax(0, .8fr) minmax(150px, 1.2fr);
  align-items: start;
  gap: 10px;
  padding: 2px 2px 0;
  color: #fff;
}

.step3-energy-intro.is-battery {
  margin-top: 6px;
  padding-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, .16);
}

.step3-energy-intro strong {
  font-size: 14px;
  line-height: 1.15;
}

.step3-energy-intro span {
  color: rgba(239, 246, 244, .72);
  font-size: 10px;
  line-height: 1.35;
}

.step3-energy-options {
  display: grid;
  gap: 7px;
}

.step3-energy-options.is-solar {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.step3-energy-options.is-battery {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.step3-energy-options button {
  position: relative;
  display: grid;
  min-width: 0;
  min-height: 0;
  align-content: start;
  gap: 6px;
  padding: 4px 4px 7px;
  border: 1px solid rgba(223, 236, 233, .28);
  border-radius: 8px;
  color: #fff;
  background: rgba(10, 28, 34, .38);
  cursor: pointer;
  text-align: left;
  transition: border-color .16s ease, background .16s ease, transform .16s ease;
}

.step3-energy-options button:hover {
  border-color: rgba(255, 255, 255, .52);
  background: rgba(255, 255, 255, .1);
  transform: translateY(-1px);
}

.step3-energy-options button.is-active {
  border: 2px solid var(--accent);
  padding: 3px 3px 6px;
  background: rgba(255, 255, 255, .1);
  box-shadow: 0 6px 15px rgba(8, 24, 30, .24);
}

.step3-energy-options button > span:last-child {
  display: grid;
  gap: 2px;
  padding-inline: 3px;
}

.step3-energy-options button strong {
  font-size: 12px;
  line-height: 1.1;
}

.step3-energy-options button small {
  min-width: 0;
  color: rgba(239, 246, 244, .72);
  font-size: 8.5px;
  font-weight: 550;
  line-height: 1.2;
}

.step3-energy-preview {
  display: block;
  width: 100%;
  aspect-ratio: 1.55 / 1;
  border-radius: 5px;
  background-image: url("./assets/ui/energy/energy-options.png");
  background-repeat: no-repeat;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .18);
}

.step3-energy-preview.is-solar-standard,
.step3-energy-preview.is-solar-none,
.step3-energy-preview.is-solar-six {
  background-size: 340% 667%;
}

.step3-energy-preview.is-solar-standard { background-position: 8.2% 23.7%; }
.step3-energy-preview.is-solar-none { background-position: 52.7% 23.7%; }
.step3-energy-preview.is-solar-six { background-position: 94.7% 23.7%; }

.step3-energy-preview.is-battery-yes {
  aspect-ratio: 1.45 / 1;
  background-image: url("./assets/ui/energy/battery-options-reference.png");
  background-position: 68% center;
  background-size: 425% 116%;
}

.step3-energy-no-battery {
  position: relative;
  display: grid;
  width: 100%;
  aspect-ratio: 1.45 / 1;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(173, 209, 220, .42);
  border-radius: 5px;
  color: transparent;
  background-image: url("./assets/ui/energy/battery-options-reference.png");
  background-position: left center;
  background-repeat: no-repeat;
  background-size: 425% 100%;
  font-size: 0;
  line-height: 1;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .05);
}

.step3-energy-no-battery::before {
  display: none;
}

.step3-energy-options.is-battery button.is-active::after {
  position: absolute;
  top: 7px;
  right: 7px;
  z-index: 2;
  display: grid;
  width: 18px;
  height: 18px;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: var(--accent);
  box-shadow: 0 2px 7px rgba(10, 27, 34, .28);
  content: "✓";
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
}

.step3-energy-options .step3-price-button-hint {
  display: inline-flex;
  width: fit-content;
  margin-top: 3px;
  padding: 3px 5px;
  border-radius: 4px;
  color: #422b12;
  background: #ffd18d;
  font-size: 7.5px;
  font-weight: 850;
  opacity: 1;
}

.step3-category[data-step3-category="energy"] .step3-price-notice {
  background:
    linear-gradient(90deg, rgba(8, 25, 32, .96), rgba(8, 25, 32, .56)),
    url("./assets/ui/energy/energy-options.png") 93.4% 64.5% / 482% 535% no-repeat;
}

.step3-category[data-step3-category]:not([data-step3-category="storage"]) > .step3-category-summary {
  position: relative;
  isolation: isolate;
  min-height: 66px;
  overflow: hidden;
  padding-block: 8px;
  border-radius: 9px;
  background: linear-gradient(90deg, rgba(17, 42, 50, .98), rgba(22, 51, 57, .88));
}

.step3-category[data-step3-category]:not([data-step3-category="storage"]) > .step3-category-summary::after {
  position: absolute;
  inset: 0 0 0 27%;
  z-index: -1;
  background-image:
    linear-gradient(90deg, rgba(18, 44, 52, .98) 0%, rgba(18, 44, 52, .7) 26%, rgba(18, 44, 52, .08) 72%),
    url("./assets/ui/menu/menu-sections.png");
  background-position: center, 75.1% var(--step3-menu-image-y, 24.2%);
  background-repeat: no-repeat;
  background-size: 100% 100%, 261% 850%;
  content: "";
  opacity: .9;
  pointer-events: none;
}

.step3-category[data-step3-category="roof"] { --step3-menu-image-y: 39.3%; }
.step3-category[data-step3-category="facade"] { --step3-menu-image-y: 55%; }
.step3-category[data-step3-category="frames"] { --step3-menu-image-y: 70.3%; }
.step3-category[data-step3-category="energy"] { --step3-menu-image-y: 85.8%; }

.step3-category[data-step3-category]:not([data-step3-category="storage"]) > .step3-category-summary > * {
  position: relative;
  z-index: 1;
}

.step3-category[data-step3-category]:not([data-step3-category="storage"]) .step3-category-icon {
  width: 40px;
  height: 40px;
  border-color: rgba(255, 255, 255, .48);
  border-radius: 9px;
  color: #fff;
  background:
    radial-gradient(circle at 45% 20%, rgba(255, 255, 255, .28), transparent 42%),
    color-mix(in srgb, var(--part-accent) 60%, rgba(16, 39, 48, .88));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .28), 0 5px 15px color-mix(in srgb, var(--part-accent) 24%, transparent);
}

.step3-category[data-step3-category]:not([data-step3-category="storage"]) .step3-category-title strong {
  color: #fff;
  font-size: 13px;
  letter-spacing: .01em;
  text-shadow: 0 2px 8px rgba(5, 17, 22, .7);
}

.step3-category[data-step3-category]:not([data-step3-category="storage"]) .step3-category-title small {
  color: rgba(232, 242, 241, .72);
  font-size: 10px;
  text-shadow: 0 1px 5px rgba(5, 17, 22, .78);
}

.step3-category[data-step3-category]:not([data-step3-category="storage"]) .step3-category-chevron {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, .3);
  border-radius: 50%;
  background: rgba(31, 63, 69, .72);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .14), 0 4px 12px rgba(5, 18, 23, .22);
  transform: none;
}

.step3-category[data-step3-category]:not([data-step3-category="storage"]) .step3-category-chevron::before {
  width: 7px;
  height: 7px;
  border-right: 2px solid rgba(255, 255, 255, .88);
  border-bottom: 2px solid rgba(255, 255, 255, .88);
  content: "";
  transform: translateY(-2px) rotate(45deg);
}

.step3-category[data-step3-category]:not([data-step3-category="storage"]).is-open .step3-category-chevron {
  transform: none;
}

.step3-category[data-step3-category]:not([data-step3-category="storage"]).is-open .step3-category-chevron::before {
  transform: translateY(2px) rotate(225deg);
}

.step3-option-row.is-visual-row {
  min-width: 0;
  padding: 8px;
  border: 1px solid rgba(225, 237, 234, .2);
  border-radius: 7px;
  background: rgba(255, 255, 255, .075);
}

.step3-option-row.is-visual-row .step3-option-label > span {
  color: #f4f8f7;
  font-size: 11px;
  font-weight: 950;
}

.step3-option-row.is-visual-row .step3-option-buttons {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 5px;
  padding: 0;
  border: 0;
  background: transparent;
}

.step3-option-row.is-compact-visual-row .step3-option-buttons {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.step3-option-row[data-step3-option-row="frames.frameColor"] .step3-option-buttons,
.step3-option-row[data-step3-option-row="frames.windowColor"] .step3-option-buttons {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.step3-option-row.is-door-color-row .step3-option-buttons {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}

.step3-option-row.is-door-color-row .step3-option-buttons button {
  grid-column: span 2;
}

.step3-option-row.is-door-color-row .step3-option-buttons button:nth-child(4) {
  grid-column: 2 / span 2;
}

.step3-option-row.is-door-color-row .step3-option-preview {
  aspect-ratio: .76 / 1;
  background-position: center;
}

.step3-option-row.is-door-color-row .step3-option-name {
  font-size: 8px;
}

.step3-option-row[data-step3-option-row="frames.frameColor"] .step3-option-name,
.step3-option-row[data-step3-option-row="frames.windowColor"] .step3-option-name {
  font-size: 9px;
}

.step3-option-row.is-visual-row .step3-option-buttons button {
  display: grid;
  min-width: 0;
  min-height: 0;
  gap: 4px;
  padding: 2px 2px 4px;
  border: 2px solid transparent;
  border-radius: 6px;
  line-height: 1.05;
  color: rgba(247, 250, 249, .88);
  background: rgba(10, 28, 34, .42);
}

.step3-option-row.is-visual-row .step3-option-buttons button:hover {
  border-color: rgba(241, 247, 245, .32);
  color: #fff;
  background: rgba(255, 255, 255, .11);
}

.step3-option-row.is-visual-row .step3-option-buttons button.is-active,
.step3-option-row.is-visual-row .step3-option-buttons button.is-original-option.is-active {
  border-color: var(--accent);
  color: #fff;
  background: rgba(255, 255, 255, .12);
  box-shadow: 0 4px 12px rgba(8, 24, 30, .24);
}

.step3-option-name {
  min-width: 0;
  overflow: hidden;
  font-size: 8px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.step3-option-preview {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 1 / .82;
  border: 1px solid rgba(28, 44, 77, .16);
  border-radius: 4px;
  background:
    radial-gradient(circle at 73% 38%, rgba(255, 255, 255, .64) 0 5%, transparent 6%),
    linear-gradient(155deg, transparent 48%, rgba(63, 103, 63, .74) 49% 68%, rgba(30, 67, 43, .82) 69%),
    linear-gradient(180deg, #d8e8e8 0 48%, #7eaa78 49% 100%);
  box-shadow: inset 0 0 12px rgba(28, 44, 77, .12);
  overflow: hidden;
}

.step3-option-preview.has-photo {
  background-image: var(--step3-preview-image);
  background-position: center;
  background-size: cover;
}

.step3-option-preview.has-photo::before,
.step3-option-preview.has-photo::after,
.step3-option-preview.has-photo.is-frame > i {
  display: none;
}

.step3-option-preview.has-photo.is-open-window > i {
  display: block;
  right: 5%;
  top: 10%;
  width: 42%;
  height: 72%;
  border: 4px solid var(--step3-preview-color);
  border-left-width: 7px;
  background: rgba(214, 233, 234, .12);
  transform: perspective(70px) rotateY(-17deg);
}

.step3-option-preview::before {
  position: absolute;
  left: 6%;
  top: -4%;
  bottom: -5%;
  width: 29%;
  border-right: 3px solid color-mix(in srgb, var(--step3-preview-color) 82%, #000);
  background: linear-gradient(90deg, color-mix(in srgb, var(--step3-preview-color) 70%, #fff), var(--step3-preview-color));
  box-shadow: 3px 0 5px rgba(0, 0, 0, .24);
  content: "";
}

.step3-option-preview::after {
  position: absolute;
  left: 31%;
  right: 0;
  top: 48%;
  height: 8%;
  background: var(--step3-preview-color);
  box-shadow: 0 2px 4px rgba(0, 0, 0, .18);
  content: "";
}

.step3-option-preview > i {
  position: absolute;
  right: 7%;
  top: 8%;
  z-index: 1;
  width: 43%;
  height: 68%;
  border: 4px solid var(--step3-preview-color);
  border-left-width: 7px;
  border-radius: 2px;
  box-shadow: 0 2px 7px rgba(0, 0, 0, .24);
}

.step3-option-preview.is-open-window > i {
  right: 4%;
  transform: perspective(70px) rotateY(-16deg);
  transform-origin: right center;
}

.step3-option-preview.is-door::before {
  left: 18%;
  top: 5%;
  bottom: 0;
  width: 58%;
  border: 5px solid color-mix(in srgb, var(--step3-preview-color) 82%, #000);
  background: var(--step3-preview-color);
}

.step3-option-preview.is-door::after {
  left: auto;
  right: 29%;
  top: 52%;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #d8b468;
}

.step3-option-preview.is-door > i,
.step3-option-preview.is-material > i,
.step3-option-preview.is-glass > i {
  display: none;
}

.step3-option-preview.is-material {
  background:
    repeating-linear-gradient(98deg, transparent 0 7px, rgba(255, 255, 255, .16) 8px 9px),
    linear-gradient(145deg, color-mix(in srgb, var(--step3-preview-color) 76%, #fff), var(--step3-preview-color));
}

.step3-option-preview.is-material::before {
  left: 15%;
  top: 8%;
  bottom: 8%;
  width: 70%;
  border: 7px solid var(--step3-preview-color);
  background: linear-gradient(180deg, rgba(217, 235, 237, .82), rgba(118, 157, 164, .58));
  box-shadow: 2px 3px 6px rgba(0, 0, 0, .2);
}

.step3-option-preview.is-material::after {
  display: none;
}

.step3-option-preview.is-glass {
  background:
    linear-gradient(90deg, transparent 31%, rgba(56, 88, 96, .55) 32% 34%, transparent 35% 65%, rgba(56, 88, 96, .55) 66% 68%, transparent 69%),
    linear-gradient(180deg, rgba(226, 239, 239, .86), rgba(104, 149, 154, .56));
}

.step3-option-preview.is-glass::before,
.step3-option-preview.is-glass::after {
  display: none;
}

.step3-combination-card {
  --combination-frame-color: #383e42;
  --combination-window-color: #e9e0d2;
  display: grid;
  grid-template-columns: minmax(122px, .78fr) minmax(0, 1.35fr);
  min-height: 148px;
  border: 1px solid rgba(220, 235, 231, .32);
  border-radius: 7px;
  background:
    radial-gradient(circle at 16% 0%, rgba(132, 169, 137, .2), transparent 42%),
    rgba(18, 43, 48, .58);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .08), 0 8px 20px rgba(8, 24, 29, .2);
  overflow: hidden;
}

.step3-combination-copy {
  display: grid;
  align-content: start;
  gap: 4px;
  padding: 10px;
}

.step3-combination-copy > strong {
  color: #fff;
  font-size: 12px;
}

.step3-combination-copy > span {
  color: rgba(235, 243, 241, .76);
  font-size: 9px;
  font-weight: 750;
  line-height: 1.3;
}

.step3-combination-copy dl {
  display: grid;
  gap: 5px;
  margin: 6px 0 0;
}

.step3-combination-copy dl > div {
  display: grid;
  grid-template-columns: 24px 1fr;
  column-gap: 6px;
  padding: 5px;
  border: 1px solid rgba(222, 236, 232, .24);
  border-radius: 5px;
  background: rgba(255, 255, 255, .055);
}

.step3-combination-copy dt,
.step3-combination-copy dd {
  margin: 0;
  font-size: 8px;
  font-weight: 850;
}

.step3-combination-copy dt {
  display: contents;
  color: rgba(229, 240, 237, .68);
}

.step3-combination-copy dd {
  grid-column: 2;
  color: #fff;
}

.step3-combination-copy dt i {
  grid-column: 1;
  grid-row: 1 / span 2;
  width: 24px;
  height: 24px;
  border: 1px solid rgba(238, 246, 244, .46);
  border-radius: 4px;
  background: var(--selected-color);
}

.step3-combination-preview {
  position: relative;
  min-width: 0;
  background-image: var(--combination-image);
  background-position: center;
  background-size: cover;
  overflow: hidden;
}

.step3-option-notice {
  margin: 0;
  padding: 8px 10px;
  border: 1px solid rgba(199, 151, 47, .28);
  border-radius: 7px;
  color: #6f5120;
  background: #fff8e8;
  font-size: 11px;
  font-weight: 750;
  line-height: 1.35;
}

.step3-option-notice[hidden] {
  display: none;
}

.step3-hover-label {
  position: absolute;
  left: 0;
  top: 0;
  z-index: 6;
  padding: 7px 10px;
  border: 1px solid color-mix(in srgb, var(--accent) 60%, #fff);
  border-radius: 6px;
  color: #fff;
  background: color-mix(in srgb, var(--steel) 92%, #000);
  box-shadow: 0 10px 28px rgba(28, 44, 77, .22);
  font-size: 12px;
  font-weight: 900;
  line-height: 1;
  pointer-events: none;
  white-space: nowrap;
  will-change: transform;
}

.step3-hover-label.is-measure-label {
  display: grid;
  gap: 6px;
  min-width: 150px;
  padding: 9px 10px;
  line-height: 1.15;
}

.step3-hover-label.is-measure-label b {
  color: #fff;
  font-size: 12px;
  font-weight: 950;
}

.step3-hover-label.is-measure-label span {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  color: rgba(255, 255, 255, .82);
  font-size: 11px;
  font-weight: 800;
}

.step3-hover-label.is-measure-label em {
  font-style: normal;
}

.step3-hover-label.is-measure-label strong {
  color: #fff;
  font-size: 11px;
  font-weight: 950;
}

.step3-hover-label[hidden] {
  display: none !important;
}

.step3-view-controls {
  position: absolute;
  left: 50%;
  right: auto;
  bottom: 14px;
  z-index: 5;
  display: flex;
  align-items: end;
  width: min(580px, calc(100% - 420px));
  min-width: 220px;
  gap: 8px;
  pointer-events: auto;
  transform: translateX(-50%);
}

body:not(.is-customize-step) .step3-view-controls,
.step3-view-controls[hidden] {
  display: none !important;
}

.levels-panel {
  position: relative;
  z-index: 6;
  width: 524px;
  margin-left: 0;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.levels-panel[hidden] {
  display: none !important;
}

.levels-panel-head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 4px 8px;
}

.levels-panel-head > span {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 6px;
  color: #fff;
  background: #2e4d5f;
  font-size: 15px;
}

.levels-panel-head strong,
.levels-panel-head small,
.levels-panel-options button span:last-child {
  display: block;
}

.levels-panel-head strong {
  font-size: 13px;
}

.levels-panel-head small,
.levels-panel-options small {
  color: var(--muted);
  font-size: 10px;
}

.levels-panel-options {
  display: grid;
  grid-template-columns: 1fr;
  gap: 7px;
}

.levels-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(104px, 1fr));
  gap: 7px;
}

.levels-panel-options button {
  position: relative;
  display: block;
  min-height: 94px;
  padding: 0;
  border: 1px solid rgba(220, 226, 232, .86);
  border-radius: 8px;
  color: var(--ink);
  background: #dce7ec;
  cursor: pointer;
  overflow: hidden;
  text-align: left;
  transition: border-color .16s ease, box-shadow .16s ease, transform .16s ease;
}

.levels-panel-options button:hover {
  border-color: rgba(199, 79, 47, .38);
  box-shadow: 0 8px 18px rgba(20, 35, 50, .14);
  transform: translateY(-1px);
}

.levels-panel-options button[aria-pressed="true"] {
  border-color: rgba(199, 79, 47, .42);
  background: #fff;
  box-shadow: 0 5px 14px rgba(20, 35, 50, .1);
}

.levels-option-thumb {
  position: absolute;
  inset: 0;
  display: block;
  background: linear-gradient(145deg, #dcebf2, #b9cbd3);
  background-position: center;
  background-size: cover;
  transition: transform .2s ease;
}

.levels-panel-options button:hover .levels-option-thumb {
  transform: scale(1.035);
}

.levels-panel-options button::after {
  position: absolute;
  inset: 36% 0 0;
  z-index: 1;
  background: linear-gradient(180deg, transparent, rgba(9, 18, 24, .82));
  content: "";
  pointer-events: none;
}

.levels-option-copy {
  position: absolute;
  left: 8px;
  right: 8px;
  bottom: 7px;
  z-index: 2;
  color: #fff;
}

.levels-option-copy strong,
.levels-option-copy small {
  display: block;
  color: inherit;
}

.levels-option-copy strong {
  font-size: 11px;
  line-height: 1.15;
}

.levels-option-copy small {
  margin-top: 2px;
  font-size: 8px;
  opacity: .82;
}

.levels-switcher {
  width: 250px;
  padding: 14px;
  border: 1px solid rgba(46, 77, 95, .14);
  border-radius: 8px;
  background: rgba(255, 255, 255, .96);
  box-shadow: 0 18px 44px rgba(20, 35, 50, .18);
  backdrop-filter: blur(16px);
}

.levels-switcher-head {
  display: grid;
  gap: 3px;
  margin-bottom: 12px;
}

.levels-switcher-head strong {
  color: var(--steel);
  font-size: 16px;
  font-weight: 950;
}

.levels-switcher-body {
  position: relative;
  min-height: calc(var(--level-count) * 52px);
  border-radius: 2px;
  background:
    linear-gradient(
      180deg,
      rgba(255, 255, 255, .96) 0%,
      rgba(255, 255, 255, .88) var(--level-fill-percent, 0%),
      rgba(255, 255, 255, .18) calc(var(--level-fill-percent, 0%) + 12%),
      transparent calc(var(--level-fill-percent, 0%) + 18%)
    ),
    linear-gradient(180deg, var(--accent), var(--accent-dark));
  overflow: hidden;
}

.levels-switcher-body::before {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, .16), transparent 36%, rgba(255, 255, 255, .08)),
    repeating-linear-gradient(180deg, rgba(255, 255, 255, .16) 0 1px, transparent 1px 52px);
  content: "";
  pointer-events: none;
}

.levels-switcher-body input[type="range"] {
  position: absolute;
  left: 50%;
  top: 12px;
  z-index: 0;
  width: calc(100% - 28px);
  height: calc(100% - 24px);
  opacity: 0;
  cursor: ns-resize;
  pointer-events: none;
  transform: translateX(-50%) rotate(90deg);
  transform-origin: center;
}

.levels-switcher-handle {
  position: absolute;
  right: 16px;
  top: calc(((100% - 32px) / var(--level-steps)) * var(--active-level-index) + 10px);
  z-index: 6;
  display: grid;
  width: 46px;
  height: 24px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, .84);
  border-radius: 999px;
  background: var(--accent);
  box-shadow: 0 8px 18px rgba(20, 35, 50, .22);
  cursor: grab;
  touch-action: none;
  user-select: none;
  transition: top .08s linear, background .16s ease, box-shadow .16s ease;
}

.levels-switcher-handle.is-dragging {
  cursor: grabbing;
  box-shadow: 0 10px 24px rgba(20, 35, 50, .28);
}

.levels-switcher-handle::before {
  color: #fff;
  content: "☰";
  font-size: 15px;
  line-height: 1;
}

.levels-switcher-options {
  position: relative;
  z-index: 2;
  display: grid;
}

.levels-switcher-options button {
  min-height: 52px;
  padding: 0 76px 0 18px;
  border: 0;
  border-radius: 0;
  color: rgba(28, 44, 77, .78);
  background: transparent;
  cursor: pointer;
  font-size: 16px;
  font-weight: 850;
  text-align: left;
  transition: color .16s ease, background .16s ease;
}

.levels-switcher-options button[aria-pressed="true"],
.levels-switcher-options button:hover {
  text-shadow: 0 1px 8px rgba(28, 44, 77, .2);
}

.levels-switcher-options button::after {
  display: none;
}

.levels-switcher-options button span {
  display: inline;
  position: relative;
  z-index: 2;
}

.scene-hud .levels-switcher-options button span {
  display: inline;
  max-width: none;
  padding: 0;
  border: 0;
  border-radius: 0;
  color: inherit;
  background: transparent;
  box-shadow: none;
  font-size: inherit;
  font-weight: inherit;
}

.levels-switcher-options button:hover,
.levels-switcher-options button[aria-pressed="true"] {
  color: var(--steel);
  background: rgba(255, 255, 255, .10);
}

.step3-view-controls > button,
.step3-view-controls details {
  border: 1px solid rgba(46, 77, 95, .16);
  border-radius: 10px;
  background: rgba(250, 252, 253, .96);
  box-shadow: 0 14px 34px rgba(20, 35, 50, .16);
  backdrop-filter: blur(14px);
}

.step3-view-controls details {
  flex: 0 1 100%;
  max-width: 580px;
  overflow: hidden;
}

.step3-view-controls > details.step3-levels-menu,
.step3-view-controls > details.step3-views-menu {
  min-width: 0;
  max-width: none;
  flex: 1 1 0;
}

.step3-view-controls details[open] {
  display: flex;
  flex-direction: column-reverse;
  border-color: transparent;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
  overflow: visible;
}

.step3-view-controls details[open] summary {
  border: 1px solid rgba(46, 77, 95, .16);
  box-shadow: 0 14px 34px rgba(20, 35, 50, .16), inset 0 1px 0 rgba(255, 255, 255, .9);
}

.step3-view-controls button,
.step3-view-controls summary {
  color: #1c2a34;
  cursor: pointer;
  font-size: 12px;
  font-weight: 900;
}

.step3-view-controls > button {
  position: relative;
  display: grid;
  min-height: 76px;
  padding: 0;
  flex: 0 0 150px;
  overflow: hidden;
}

.step3-view-controls summary {
  display: flex;
  align-items: center;
  min-height: 36px;
  padding: 0 12px;
  border-radius: 10px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, .96), rgba(235, 242, 246, .96));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .9);
  list-style: none;
}

.step3-view-controls summary::before {
  display: inline-grid;
  width: 24px;
  height: 24px;
  margin-right: 8px;
  place-items: center;
  border-radius: 6px;
  color: #fff;
  background: linear-gradient(135deg, #174b6d, #c74f2f);
  content: "▣";
  font-size: 12px;
  line-height: 1;
}

.step3-view-controls summary::-webkit-details-marker {
  display: none;
}

.step3-view-controls summary::after {
  width: 8px;
  height: 8px;
  margin-left: auto;
  border-top: 2px solid #657482;
  border-left: 2px solid #657482;
  content: "";
  transform: rotate(45deg);
  transition: transform .18s ease;
}

.step3-view-controls details[open] summary::after {
  transform: rotate(225deg);
}

.step3-view-controls .step3-levels-menu summary::before {
  content: "▤";
}

.step3-view-controls .step3-levels-menu[open] summary,
.step3-view-controls .step3-levels-menu summary.is-active {
  color: #8c351e;
  box-shadow: inset 0 0 0 1px rgba(199, 79, 47, .36);
}

.scene-actions .scene-levels-menu {
  position: relative;
  border: 1px solid rgba(255, 255, 255, .68);
  border-radius: 7px;
  background: rgba(255, 255, 255, .86);
  box-shadow: 0 10px 30px rgba(20, 35, 50, .1);
}

.scene-actions .scene-levels-menu[hidden] {
  display: none !important;
}

.scene-actions .scene-levels-menu summary {
  display: flex;
  align-items: center;
  min-height: 42px;
  padding: 0 13px;
  color: var(--steel);
  cursor: pointer;
  font-size: 13px;
  font-weight: 950;
  list-style: none;
}

.scene-actions .scene-levels-menu summary::-webkit-details-marker {
  display: none;
}

.scene-actions .scene-levels-menu summary::before {
  width: 22px;
  height: 22px;
  margin-right: 8px;
  display: inline-grid;
  place-items: center;
  border-radius: 5px;
  color: #fff;
  background: linear-gradient(135deg, #174b6d, #c74f2f);
  content: "▤";
  font-size: 11px;
}

.scene-actions .scene-levels-menu summary::after {
  width: 7px;
  height: 7px;
  margin-left: 10px;
  border-top: 2px solid #657482;
  border-left: 2px solid #657482;
  content: "";
  transform: rotate(225deg);
  transition: transform .18s ease;
}

.scene-actions .scene-levels-menu[open] summary,
.scene-actions .scene-levels-menu summary.is-active {
  color: #8c351e;
  box-shadow: inset 0 0 0 1px rgba(199, 79, 47, .28);
}

.scene-actions .scene-levels-menu[open] summary::after {
  transform: rotate(45deg);
}

.scene-actions .scene-levels-menu .levels-panel {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  width: min(280px, calc(100vw - 28px));
  padding: 0;
  border: 0;
  background: transparent;
}

.step3-side-view-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(96px, 1fr));
  width: 524px;
  gap: 7px;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.step3-side-view-grid button {
  position: relative;
  display: block;
  min-height: 82px;
  padding: 0;
  border: 1px solid rgba(220, 226, 232, .86);
  border-radius: 8px;
  background: #fff;
  overflow: hidden;
  text-align: left;
  transition: border-color .16s ease, box-shadow .16s ease, transform .16s ease;
}

.step3-view-controls button:hover,
.step3-view-controls button.is-active {
  border-color: rgba(199, 79, 47, .32);
  box-shadow: 0 8px 18px rgba(20, 35, 50, .12);
}

.step3-view-controls button.is-active {
  color: #8c351e;
}

.step3-view-controls button > span:not(.step3-view-thumb) {
  position: absolute;
  left: 50%;
  bottom: 8px;
  z-index: 2;
  max-width: calc(100% - 16px);
  padding: 6px 8px;
  border-radius: 5px;
  color: #fff;
  background: rgba(18, 24, 30, .72);
  box-shadow: 0 8px 18px rgba(0, 0, 0, .18);
  font-size: 12px;
  line-height: 1;
  opacity: 0;
  overflow: hidden;
  text-align: center;
  text-overflow: ellipsis;
  transform: translate(-50%, 4px);
  transition: opacity .16s ease, transform .16s ease, background .16s ease;
  white-space: nowrap;
}

.step3-view-controls button:hover > span:not(.step3-view-thumb),
.step3-view-controls button:focus-visible > span:not(.step3-view-thumb),
.step3-view-controls button.is-active > span:not(.step3-view-thumb) {
  opacity: 1;
  transform: translate(-50%, 0);
}

.step3-view-controls button.is-active > span:not(.step3-view-thumb) {
  background: rgba(0, 0, 0, .88);
}

.step3-view-controls button::after {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(180deg, transparent 42%, rgba(0, 0, 0, .34));
  content: "";
  opacity: 0;
  pointer-events: none;
  transition: opacity .16s ease;
}

.step3-view-controls button:hover::after,
.step3-view-controls button:focus-visible::after {
  opacity: .72;
}

.step3-view-controls button.is-active::after {
  background: rgba(0, 0, 0, .30);
  opacity: 1;
}

.step3-view-controls .levels-panel-options button > .levels-option-thumb,
.step3-view-controls .levels-panel-options button:hover > .levels-option-thumb,
.step3-view-controls .levels-panel-options button:focus-visible > .levels-option-thumb,
.step3-view-controls .levels-panel-options button[aria-pressed="true"] > .levels-option-thumb {
  position: absolute;
  inset: 0;
  z-index: 0;
  display: block;
  max-width: none;
  padding: 0;
  border-radius: 0;
  background-color: #dce7ec;
  background-position: center;
  background-size: cover;
  box-shadow: none;
  opacity: 1;
  transform: none;
}

.step3-view-controls .levels-panel-options button:hover > .levels-option-thumb {
  transform: scale(1.035);
}

.step3-view-controls .levels-panel-options button > .levels-option-copy,
.step3-view-controls .levels-panel-options button:hover > .levels-option-copy,
.step3-view-controls .levels-panel-options button:focus-visible > .levels-option-copy,
.step3-view-controls .levels-panel-options button[aria-pressed="true"] > .levels-option-copy {
  position: absolute;
  left: 8px;
  right: 8px;
  bottom: 7px;
  z-index: 2;
  display: block;
  max-width: none;
  padding: 0;
  border-radius: 0;
  color: #fff;
  background: transparent;
  box-shadow: none;
  line-height: 1.15;
  opacity: 1;
  overflow: visible;
  text-align: left;
  text-overflow: clip;
  transform: none;
  white-space: normal;
}

.step3-view-controls .levels-panel-options button::after,
.step3-view-controls .levels-panel-options button:hover::after,
.step3-view-controls .levels-panel-options button:focus-visible::after,
.step3-view-controls .levels-panel-options button[aria-pressed="true"]::after {
  position: absolute;
  inset: 36% 0 0;
  z-index: 1;
  display: block;
  background: linear-gradient(180deg, transparent, rgba(9, 18, 24, .82));
  content: "";
  opacity: 1;
  pointer-events: none;
}

.step3-view-thumb {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  min-height: 76px;
  border: 1px solid rgba(46, 77, 95, .18);
  border-radius: inherit;
  background:
    linear-gradient(180deg, rgba(223, 234, 241, .95), rgba(246, 249, 251, .95));
  background-position: center;
  background-size: cover;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .9);
}

.step3-view-thumb.is-rendered::after {
  display: none;
}

.step3-side-view-grid .step3-view-thumb {
  width: 100%;
  height: 100%;
  min-height: 92px;
}

.step3-view-thumb::after {
  position: absolute;
  border-radius: 3px;
  background:
    linear-gradient(180deg, #8292a0 0 28%, transparent 29%),
    linear-gradient(90deg, transparent 15%, #f5f6f7 16% 28%, transparent 29% 44%, #f5f6f7 45% 58%, transparent 59% 72%, #f5f6f7 73% 85%, transparent 86%),
    #d8c4ac;
  box-shadow: 0 0 0 1px rgba(46, 77, 95, .16);
  content: "";
}

.step3-view-thumb.is-top::after {
  inset: 9px 14px;
  background:
    linear-gradient(90deg, rgba(46, 77, 95, .22) 0 2px, transparent 2px calc(100% - 2px), rgba(46, 77, 95, .22) calc(100% - 2px)),
    linear-gradient(0deg, rgba(46, 77, 95, .22) 0 2px, transparent 2px calc(100% - 2px), rgba(46, 77, 95, .22) calc(100% - 2px)),
    #d8c4ac;
}

.step3-view-thumb.is-front::after,
.step3-view-thumb.is-back::after {
  left: 14%;
  right: 14%;
  top: 12px;
  height: 18px;
}

.step3-view-thumb.is-left::after,
.step3-view-thumb.is-right::after {
  top: 8px;
  bottom: 8px;
  width: 24px;
}

.step3-view-thumb.is-left::after {
  left: 22%;
}

.step3-view-thumb.is-right::after {
  right: 22%;
}

.step3-hotspot-layer {
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
}

.step3-hotspot-layer[hidden] {
  display: none !important;
}

.step3-hotspot {
  position: absolute;
  left: 0;
  top: 0;
  display: flex;
  align-items: center;
  gap: 0;
  min-height: 20px;
  padding: 3px;
  border: 0;
  color: #10283c;
  background: rgba(246, 251, 255, .9);
  border-radius: 999px;
  box-shadow: 0 8px 22px rgba(20, 35, 50, .16);
  cursor: pointer;
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
  opacity: .92;
  pointer-events: auto;
  transform-origin: 0 0;
  transition: opacity .18s ease, box-shadow .18s ease, background .18s ease, padding .18s ease, gap .18s ease;
  will-change: transform;
}

.step3-hotspot:hover,
.step3-hotspot:focus-visible,
.step3-hotspot.is-active {
  opacity: 1;
  background: rgba(239, 249, 255, .98);
  box-shadow: 0 10px 26px rgba(20, 35, 50, .22);
}

.step3-hotspot:hover,
.step3-hotspot:focus-visible {
  gap: 5px;
  padding-right: 8px;
}

.step3-hotspot-dot {
  position: relative;
  display: inline-block;
  width: 14px;
  height: 14px;
  margin-left: 0;
  border: 2px solid #1b92ff;
  border-radius: 999px;
  background: rgba(255, 255, 255, .95);
}

.step3-hotspot-dot::after {
  position: absolute;
  inset: -4px;
  border: 1px solid rgba(27, 146, 255, .34);
  border-radius: inherit;
  content: "";
  animation: step3HotspotPulse 1.8s ease-out infinite;
}

.step3-hotspot.is-active .step3-hotspot-dot {
  border-color: #005fd1;
  background: #1b92ff;
  box-shadow: 0 0 0 2px rgba(27, 146, 255, .16);
  animation: step3SelectedDot .42s ease both;
}

.step3-hotspot-label {
  display: inline-block;
  max-width: 0;
  opacity: 0;
  overflow: hidden;
  white-space: nowrap;
  transition: max-width .2s ease, opacity .16s ease;
}

.step3-hotspot:hover .step3-hotspot-label,
.step3-hotspot:focus-visible .step3-hotspot-label {
  max-width: 120px;
  opacity: 1;
}

@keyframes step3CategoryIn {
  from {
    opacity: .72;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes step3PanelIn {
  from {
    opacity: 0;
    transform: translate3d(-18px, 0, 0) scale(.985);
  }
  to {
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1);
  }
}

@keyframes step3OptionsIn {
  from {
    opacity: .55;
    transform: translateY(5px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes step3SelectedDot {
  0% {
    transform: scale(.82);
  }
  55% {
    transform: scale(1.12);
  }
  100% {
    transform: scale(1);
  }
}

body .visual-stage.is-step3-selecting .step3-hotspot.is-active,
body .visual-stage.is-step3-resetting .step3-hotspot.is-active {
  animation: step3SelectionLift .42s ease both;
}

@keyframes step3SelectionLift {
  0% {
    filter: brightness(1);
  }
  45% {
    filter: brightness(1.08);
  }
  100% {
    filter: brightness(1);
  }
}

@keyframes step3HotspotPulse {
  0% {
    opacity: .9;
    transform: scale(.72);
  }
  100% {
    opacity: 0;
    transform: scale(1.45);
  }
}

#threeCanvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}

.media-viewer,
.pdf-viewer {
  position: absolute;
  inset: 0;
  background: #e8eef2;
}

.media-viewer img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.media-viewer.is-plan-view {
  background:
    linear-gradient(rgba(28, 44, 77, .06) 1px, transparent 1px) 0 0 / 54px 54px,
    linear-gradient(90deg, rgba(28, 44, 77, .06) 1px, transparent 1px) 0 0 / 54px 54px,
    #f6f5f1;
  cursor: grab;
  overflow: hidden;
  touch-action: none;
}

.media-viewer.is-plan-view img {
  padding: 70px 24px 34px;
  object-fit: contain;
  transform: translate(var(--plan-pan-x, 0), var(--plan-pan-y, 0)) scale(var(--plan-zoom, 1));
  transform-origin: center center;
  transition: transform .18s ease;
  will-change: transform;
  user-select: none;
  pointer-events: none;
}

.media-viewer.is-plan-view.is-plan-dragging {
  cursor: grabbing;
}

.visual-stage.is-floor-plan .step3-config-panel,
.visual-stage.is-floor-plan .step3-view-controls,
.visual-stage.is-floor-plan .step3-hotspot-layer,
.visual-stage.is-floor-plan .step3-hover-label {
  display: none !important;
}

.media-viewer.is-panorama img {
  object-fit: cover;
}

.media-caption {
  position: absolute;
  left: 14px;
  right: 14px;
  top: 14px;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px 14px;
  max-width: calc(100% - 28px);
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, .62);
  border-radius: 6px;
  color: #26313a;
  background: rgba(255, 255, 255, .82);
  box-shadow: 0 10px 30px rgba(20, 35, 50, .1);
}

.media-caption span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.media-controls {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 14px;
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 2px;
}

.media-viewer.is-plan-view .media-caption {
  display: none;
}

.media-viewer.is-plan-view .media-controls {
  left: 14px;
  right: auto;
  top: 14px;
  bottom: auto;
  align-items: center;
  padding: 0;
  overflow: visible;
  z-index: 2;
}

.plan-floor-control {
  display: grid;
  position: relative;
  grid-template-columns: 36px minmax(0, 1fr) 24px;
  grid-template-rows: auto auto;
  align-items: center;
  gap: 10px;
  min-width: min(360px, calc(100vw - 150px));
  min-height: 58px;
  padding: 8px 14px 8px 10px;
  border: 1px solid rgba(255, 255, 255, .78);
  border-radius: 8px;
  color: var(--ink);
  background: rgba(255, 255, 255, .92);
  box-shadow: 0 14px 34px rgba(20, 35, 50, .14);
}

.plan-floor-control::after {
  display: grid;
  grid-column: 3;
  grid-row: 1 / 3;
  width: 24px;
  height: 24px;
  place-items: center;
  align-self: center;
  color: var(--ink);
  content: "⌄";
  font-size: 22px;
  font-weight: 950;
  line-height: 1;
  pointer-events: none;
}

.plan-floor-icon {
  display: grid;
  grid-row: 1 / 3;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 7px;
  color: #fff;
  background: var(--steel);
  font-size: 17px;
}

.plan-floor-label {
  align-self: end;
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.plan-floor-control select {
  grid-column: 2;
  grid-row: 2;
  align-self: start;
  width: 100%;
  padding-right: 2px;
  border: 0;
  color: var(--ink);
  background: transparent;
  cursor: pointer;
  font-size: 18px;
  font-weight: 850;
  appearance: none;
}

.plan-zoom-control {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 58px;
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, .78);
  border-radius: 8px;
  color: var(--ink);
  background: rgba(255, 255, 255, .92);
  box-shadow: 0 14px 34px rgba(20, 35, 50, .14);
}

.plan-dimension-overlay {
  position: absolute;
  z-index: 1;
  transform: translate(var(--plan-pan-x, 0), var(--plan-pan-y, 0)) scale(var(--plan-zoom, 1));
  transform-origin: center center;
  transition: transform .18s ease;
  pointer-events: auto;
}

.plan-room-target {
  position: absolute;
  z-index: 1;
  min-width: 10px;
  min-height: 10px;
  padding: 0;
  border: 1px solid rgba(28, 44, 77, 0);
  border-radius: 4px;
  background: rgba(28, 44, 77, 0);
  box-shadow: none;
  cursor: pointer;
  pointer-events: auto;
  transition: background .16s ease, border-color .16s ease, box-shadow .16s ease;
}

.plan-room-target span {
  position: absolute;
  left: 50%;
  top: 50%;
  padding: 5px 8px;
  border-radius: 999px;
  color: #fff;
  background: rgba(28, 44, 77, .9);
  font-size: 10px;
  font-weight: 950;
  opacity: 0;
  transform: translate(-50%, -50%) scale(.96);
  transition: opacity .16s ease, transform .16s ease;
  white-space: nowrap;
}

.plan-room-target:hover,
.plan-room-target:focus-visible,
.plan-room-target.is-selected {
  border-color: rgba(233, 138, 42, .64);
  background: rgba(233, 138, 42, .045);
  box-shadow: inset 0 0 0 1px rgba(233, 138, 42, .24);
}

.plan-room-target:hover span,
.plan-room-target:focus-visible span,
.plan-room-target.is-selected span {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.plan-dimension-target {
  position: absolute;
  z-index: 2;
  min-width: 2px;
  min-height: 2px;
  padding: 0;
  border: 0;
  border-radius: 2px;
  background: transparent;
  box-shadow: none;
  cursor: default;
  pointer-events: auto;
}

.plan-dimension-target::before {
  position: absolute;
  inset: 0;
  content: "";
  border-radius: 2px;
  background: rgba(233, 138, 42, 0);
  transition: background .16s ease, box-shadow .16s ease;
}

.plan-dimension-target:hover::before,
.plan-dimension-target:focus-visible::before {
  background: rgba(233, 138, 42, .11);
  box-shadow: inset 0 0 0 1px rgba(233, 138, 42, .58);
}

.plan-dimension-target.is-extension:hover::before,
.plan-dimension-target.is-extension:focus-visible::before {
  background: rgba(28, 44, 77, .09);
  box-shadow: inset 0 0 0 1px rgba(28, 44, 77, .42);
}

.plan-dimension-target span {
  position: absolute;
  left: 50%;
  bottom: calc(100% + 10px);
  display: grid;
  min-width: 126px;
  gap: 2px;
  padding: 8px 10px;
  border-radius: 7px;
  color: #fff;
  background: rgba(28, 44, 77, .96);
  box-shadow: 0 14px 28px rgba(20, 35, 50, .18);
  opacity: 0;
  pointer-events: none;
  text-align: center;
  transform: translate(-50%, 5px);
  transition: opacity .16s ease, transform .16s ease;
  white-space: nowrap;
}

.plan-dimension-target span::after {
  position: absolute;
  left: 50%;
  top: 100%;
  width: 10px;
  height: 10px;
  content: "";
  background: rgba(28, 44, 77, .96);
  transform: translate(-50%, -5px) rotate(45deg);
}

.plan-dimension-target strong,
.plan-dimension-target small {
  position: relative;
  z-index: 1;
}

.plan-dimension-target strong {
  font-size: 12px;
  font-weight: 950;
}

.plan-dimension-target small {
  color: rgba(255, 255, 255, .72);
  font-size: 10px;
  font-weight: 800;
}

.plan-dimension-target:hover span,
.plan-dimension-target:focus-visible span {
  opacity: 1;
  transform: translate(-50%, 0);
}

.plan-room-dimension {
  position: absolute;
  z-index: 3;
  display: grid;
  place-items: center;
  min-width: 54px;
  min-height: 22px;
  padding: 4px 7px;
  border-radius: 999px;
  color: #fff;
  background: var(--accent);
  box-shadow: 0 10px 22px rgba(20, 35, 50, .18);
  font-size: 11px;
  font-weight: 950;
  pointer-events: none;
  white-space: nowrap;
}

.plan-room-dimension.is-top {
  transform: translateY(-135%);
}

.plan-room-dimension.is-bottom {
  transform: translateY(35%);
}

.plan-room-dimension.is-left,
.plan-room-dimension.is-right {
  width: auto;
  min-width: 58px;
  transform-origin: center;
}

.plan-room-dimension.is-left {
  transform: translate(-100%, -50%) rotate(-90deg);
}

.plan-room-dimension.is-right {
  transform: translate(0, -50%) rotate(90deg);
}

.plan-zoom-control button {
  display: grid;
  width: 38px;
  min-width: 38px;
  height: 38px;
  min-height: 38px;
  place-items: center;
  padding: 0;
  border: 1px solid color-mix(in srgb, var(--steel) 14%, var(--line));
  border-radius: 7px;
  color: var(--ink);
  background: #fff;
  box-shadow: none;
  font-size: 22px;
  font-weight: 950;
}

.plan-zoom-control button:disabled {
  cursor: default;
  opacity: .42;
}

.plan-zoom-control span {
  min-width: 52px;
  text-align: center;
  color: var(--steel);
  font-size: 13px;
  font-weight: 950;
}

.media-controls button {
  min-width: max-content;
  min-height: 38px;
  padding: 8px 11px;
  border: 1px solid rgba(255, 255, 255, .7);
  border-radius: 6px;
  color: var(--ink);
  background: rgba(255, 255, 255, .86);
  box-shadow: 0 10px 30px rgba(20, 35, 50, .1);
  cursor: pointer;
  font-weight: 800;
}

.media-controls button.is-active {
  color: #fff;
  background: var(--accent);
  border-color: var(--accent);
}

.pdf-viewer {
  display: grid;
  grid-template-rows: 1fr auto;
  gap: 10px;
  padding: 12px;
}

.pdf-viewer img {
  width: 100%;
  height: 100%;
  min-height: 0;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  object-fit: contain;
}

.pdf-link {
  justify-self: end;
  min-width: 190px;
}

.scene-hud {
  position: absolute;
  left: 14px;
  right: 14px;
  top: 14px;
  z-index: 7;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  pointer-events: none;
}

body.is-customize-step .scene-hud > #modeHint {
  display: none;
}

body.is-build-step .scene-hud > #modeHint {
  display: none;
}

body.is-customize-step .scene-hud {
  justify-content: flex-end;
}

body.is-build-step .scene-hud {
  justify-content: flex-end;
}

.visual-stage.is-media .walk-pad,
.visual-stage.is-pdf .walk-pad {
  display: none;
}

.visual-stage.is-media:not(.is-floor-plan) .scene-hud,
.visual-stage.is-pdf .scene-hud {
  display: none;
}

.visual-stage.is-expanded {
  position: fixed;
  inset: 12px;
  z-index: 50;
  width: auto;
  height: auto;
  min-height: 0;
  flex: none;
}

body.viewer-expanded .visual-stage.is-expanded {
  height: auto;
  min-height: 0;
}

body.viewer-expanded {
  overflow: hidden;
}

.visual-stage.is-expanded .scene-hud {
  top: 18px;
}

.visual-stage.is-expanded .walk-pad {
  left: 22px;
  bottom: 22px;
}

body.is-customize-step .visual-stage.is-expanded .walk-pad {
  display: none;
}

body.is-customize-step .visual-stage.is-expanded .step3-config-panel {
  left: 0;
  top: 0;
  bottom: 0;
  width: clamp(300px, 22vw, 360px);
  max-height: none;
  gap: 0;
  padding: 0;
}

body.is-customize-step .visual-stage.is-expanded .step3-panel-head {
  top: 0;
  margin: 0;
  padding: 12px 12px 10px;
}

body.is-customize-step .visual-stage.is-expanded .step3-panel-mark {
  width: 28px;
  height: 28px;
  font-size: 14px;
}

body.is-customize-step .visual-stage.is-expanded .step3-panel-head strong {
  font-size: 15px;
}

body.is-customize-step .visual-stage.is-expanded .step3-category-list {
  gap: 8px;
  padding: 10px 12px 12px;
}

body.is-customize-step .visual-stage.is-expanded .step3-category-summary {
  min-height: 46px;
  padding: 9px 10px;
}

body.is-customize-step .visual-stage.is-expanded .step3-category-icon {
  width: 28px;
  height: 28px;
  font-size: 13px;
}

body.is-customize-step .visual-stage.is-expanded .step3-category-body-inner {
  gap: 7px;
  padding: 0 9px 9px 51px;
}

body.is-customize-step .visual-stage.is-expanded .step3-option-buttons {
  grid-template-columns: repeat(auto-fit, minmax(68px, 1fr));
  gap: 4px;
  padding: 3px;
}

body.is-customize-step .visual-stage.is-expanded .step3-option-buttons button {
  min-height: 30px;
  padding-inline: 8px;
  font-size: 11px;
}

body.is-customize-step .visual-stage.is-expanded .step3-config-panel.is-collapsed {
  left: 0;
  top: 0;
  bottom: auto;
  width: 112px;
  max-height: calc(100% - 20px);
  padding: 0;
}

body.is-customize-step .visual-stage.is-expanded .step3-config-panel.is-collapsed .step3-panel-head {
  position: static;
  margin: 0;
  padding: 12px 10px 10px;
}

body.is-customize-step .visual-stage.is-expanded .step3-view-controls {
  left: 50%;
  right: auto;
  top: auto;
  bottom: 22px;
  width: min(580px, calc(100% - 44px));
  transform: translateX(-50%);
}

body.is-customize-step .visual-stage.is-expanded:has(.step3-config-panel.is-collapsed) .step3-view-controls {
  left: 50%;
  width: min(580px, calc(100% - 44px));
}

body.is-customize-step .visual-stage.is-expanded .levels-panel {
  left: auto;
  right: auto;
  top: auto;
  bottom: auto;
}

body.is-customize-step .visual-stage.is-expanded .scene-actions .scene-levels-menu .levels-panel {
  left: auto;
  right: 0;
  top: calc(100% + 8px);
  bottom: auto;
  z-index: 12;
  width: min(312px, calc(100vw - 44px));
  max-height: calc(100vh - 116px);
  overflow: auto;
  overscroll-behavior: contain;
}

.visual-stage.is-expanded .render-variant-controls {
  left: 50%;
  right: auto;
  bottom: 22px;
  max-width: min(760px, calc(100% - 320px));
  transform: translateX(-50%);
}

.scene-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  pointer-events: auto;
}

.viewer-mode-toggle {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 42px;
  padding: 4px;
  border: 1px solid rgba(255, 255, 255, .68);
  border-radius: 7px;
  background: rgba(255, 255, 255, .86);
  box-shadow: 0 10px 30px rgba(20, 35, 50, .1);
}

.viewer-mode-button {
  min-width: 46px;
  min-height: 34px;
  border: 0;
  border-radius: 5px;
  color: var(--muted);
  background: transparent;
  cursor: pointer;
  font-weight: 950;
}

.viewer-mode-button.is-active {
  color: #fff;
  background: var(--accent);
  box-shadow: 0 8px 18px rgba(233, 138, 42, .22);
}

.scene-hud > #modeHint {
  max-width: min(480px, calc(100% - 54px));
  padding: 9px 11px;
  border: 1px solid rgba(255, 255, 255, .58);
  border-radius: 6px;
  color: #26313a;
  background: rgba(255, 255, 255, .78);
  box-shadow: 0 10px 30px rgba(20, 35, 50, .1);
  font-size: 13px;
  font-weight: 800;
  pointer-events: auto;
}

.scene-hud > #modeHint:empty {
  display: none;
}

.viewer-watermark {
  position: absolute;
  right: 20px;
  bottom: 18px;
  z-index: 4;
  padding: 0;
  color: rgba(255, 255, 255, .36);
  font-family: "Bebas Neue", "Arial Narrow", Impact, sans-serif;
  font-size: 16px;
  letter-spacing: .04em;
  line-height: 1;
  pointer-events: none;
  text-shadow: 0 1px 3px rgba(28, 44, 77, .22);
  text-transform: uppercase;
}

.icon-button {
  width: 42px;
  height: 42px;
  border: 1px solid rgba(255, 255, 255, .68);
  border-radius: 6px;
  color: var(--ink);
  background: rgba(255, 255, 255, .86);
  box-shadow: 0 10px 30px rgba(20, 35, 50, .1);
  cursor: pointer;
  font-size: 22px;
  font-weight: 800;
  pointer-events: auto;
}

.tool-button {
  min-height: 42px;
  padding: 0 12px;
  border: 1px solid rgba(255, 255, 255, .68);
  border-radius: 6px;
  color: var(--ink);
  background: rgba(255, 255, 255, .86);
  box-shadow: 0 10px 30px rgba(20, 35, 50, .1);
  cursor: pointer;
  font-weight: 900;
}

.render-variant-controls {
  position: absolute;
  right: 16px;
  bottom: 16px;
  display: flex;
  max-width: min(580px, calc(100% - 190px));
  gap: 7px;
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, .62);
  border-radius: 8px;
  background: rgba(255, 255, 255, .82);
  box-shadow: 0 14px 34px rgba(20, 35, 50, .13);
  overflow-x: auto;
  pointer-events: auto;
}

.render-variant-controls button {
  min-height: 36px;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--ink);
  background: #fff;
  cursor: pointer;
  font-size: 13px;
  font-weight: 850;
  white-space: nowrap;
}

.render-variant-controls button.is-active {
  color: #fff;
  border-color: var(--accent);
  background: var(--accent);
}

.loading-badge {
  position: absolute;
  left: 50%;
  top: 50%;
  display: grid;
  min-width: min(320px, calc(100% - 42px));
  gap: 5px;
  padding: 14px 16px;
  border: 1px solid rgba(255, 255, 255, .72);
  border-radius: 8px;
  color: var(--ink);
  background: rgba(255, 255, 255, .88);
  box-shadow: 0 18px 46px rgba(20, 35, 50, .16);
  text-align: center;
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.loading-badge::before {
  content: "";
  justify-self: center;
  width: 28px;
  height: 28px;
  border: 3px solid rgba(24, 33, 42, .16);
  border-top-color: var(--accent);
  border-radius: 999px;
  animation: bta-spin .85s linear infinite;
}

.loading-badge strong {
  font-size: 14px;
}

.loading-badge span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
}

@keyframes bta-spin {
  to {
    transform: rotate(360deg);
  }
}

.walk-pad {
  position: absolute;
  left: 16px;
  bottom: 16px;
  display: grid;
  grid-template-columns: repeat(3, 46px);
  grid-template-rows: repeat(3, 46px);
  gap: 8px;
}

.walk-pad button {
  border: 1px solid rgba(255, 255, 255, .7);
  border-radius: 6px;
  color: var(--ink);
  background: rgba(255, 255, 255, .86);
  box-shadow: 0 10px 30px rgba(20, 35, 50, .1);
  cursor: pointer;
  font-size: 20px;
  font-weight: 900;
}

.walk-pad button[data-move="forward"] {
  grid-column: 2;
}

.walk-pad button[data-move="left"] {
  grid-column: 1;
  grid-row: 2;
}

.walk-pad button[data-move="back"] {
  grid-column: 2;
  grid-row: 2;
}

.walk-pad button[data-move="right"] {
  grid-column: 3;
  grid-row: 2;
}

.walk-pad button[data-move="down"] {
  grid-column: 1;
  grid-row: 3;
}

.walk-pad button[data-move="up"] {
  grid-column: 3;
  grid-row: 3;
}

.summary-band {
  display: grid;
  grid-template-columns: 1fr;
  justify-self: end;
  width: min(100%, 520px);
}

.summary-band article {
  min-height: 82px;
  padding: 16px;
  border: 1px solid color-mix(in srgb, var(--steel) 20%, var(--line));
  border-radius: 8px;
  background:
    linear-gradient(90deg, rgba(28, 44, 77, .05), #fff 42%);
}

.summary-band span,
.summary-band strong,
.summary-band small {
  display: block;
}

.summary-band strong {
  margin-top: 4px;
  color: var(--steel);
  font-family: "Bebas Neue", "Arial Narrow", Impact, sans-serif;
  font-size: 22px;
}

.summary-band small {
  margin-top: 5px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  line-height: 1.25;
}

.quote-panel {
  display: grid;
  grid-column: 1 / -1;
  grid-template-columns: minmax(0, 1.35fr) minmax(260px, .65fr);
  align-content: start;
  gap: 14px;
}

.quote-card {
  display: grid;
  grid-template-columns: minmax(190px, 240px) minmax(0, 1fr);
  align-items: start;
  gap: 12px 18px;
  padding: 20px;
  border-top: 4px solid var(--accent);
}

.quote-card .eyebrow {
  grid-column: 1;
  color: var(--accent);
}

.quote-card h2 {
  grid-column: 1;
}

.quote-card dl {
  display: grid;
  grid-column: 2;
  grid-row: 1 / span 3;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px 12px;
  margin: 0;
}

.quote-card div {
  display: grid;
  gap: 4px;
  min-height: 64px;
  padding: 10px 12px;
  border-bottom: 1px solid color-mix(in srgb, var(--steel) 13%, var(--line));
  border-radius: 6px;
  background: linear-gradient(180deg, #fff, color-mix(in srgb, var(--steel) 4%, #fff));
}

.quote-card dt {
  font-size: 13px;
  font-weight: 850;
  text-transform: uppercase;
}

.quote-card dd {
  margin: 0;
  font-weight: 800;
  text-align: left;
}

.quote-status {
  display: block;
  grid-column: 2;
  margin: 0;
  padding: 10px 12px;
  border: 1px solid #c7d2df;
  border-radius: 6px;
  color: #1b3348;
  background: #eef5fb;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.4;
}

.quote-status[data-tone="success"] {
  border-color: #abc8b8;
  color: #163c2b;
  background: #edf8f1;
}

.full-width {
  grid-column: 2;
  justify-self: start;
  min-width: 220px;
  width: auto;
  margin-top: 0;
}

.quote-card .ghost-button.full-width {
  margin-top: -4px;
  align-self: start;
}

.notes {
  padding: 18px;
  box-shadow: none;
}

.notes p {
  margin: 8px 0 0;
  line-height: 1.5;
}

@media (max-width: 1180px) {
  .configurator {
    grid-template-columns: 380px 1fr;
  }

  .quote-panel {
    grid-template-columns: 1.4fr 1fr;
  }

  .quote-card {
    grid-template-columns: 1fr;
  }

  .quote-card .eyebrow,
  .quote-card h2,
  .quote-card dl,
  .quote-status,
  .full-width {
    grid-column: 1;
  }

  .quote-card dl {
    grid-row: auto;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .control-panel,
  .preview-area {
    min-height: auto;
  }
}

@media (max-width: 860px) {
  .app-shell {
    padding: 10px;
  }

  .topbar,
  .preview-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .preview-titlebar {
    align-items: stretch;
    flex-direction: column;
    gap: 10px;
  }

  .client-identity {
    min-width: 0;
    width: 100%;
  }

  .preview-title {
    padding-left: 0;
    border-left: 0;
  }

  .step-nav {
    overflow-x: auto;
  }

  .configurator,
  .quote-panel {
    grid-template-columns: 1fr;
  }

  body:not(.is-model-step) .configurator {
    grid-template-columns: 1fr;
  }

  .preview-area {
    order: -1;
  }

  .model-grid,
  .summary-band,
  .config-variant-controls {
    grid-template-columns: 1fr;
  }

  .preview-footer {
    grid-template-columns: minmax(240px, 1fr) minmax(280px, 1fr);
    justify-content: center;
  }

  .preview-footer > .step-nav {
    grid-column: 1;
  }

  .preview-footer > .summary-band {
    grid-column: 2;
  }

  .preview-footer > .panel-actions {
    grid-column: 1;
  }

  .preview-footer > .footer-step-nav {
    display: none;
  }

  .preview-footer .step-link,
  .preview-footer .primary-button,
  .preview-footer .ghost-button,
  .summary-band article {
    min-height: 58px;
  }

  .visual-stage {
    min-height: clamp(340px, 62svh, 540px);
  }

  body.is-build-step .visual-stage,
  body.is-customize-step .visual-stage {
    min-height: clamp(520px, 72svh, 680px);
  }

  body.is-embedded .visual-stage {
    height: 500px;
    min-height: 0;
  }

  body.is-embedded.is-build-step .visual-stage {
    height: 600px;
    min-height: 0;
  }

  body.is-build-step .panel-actions {
    max-width: none;
  }

  .view-toggle {
    flex-wrap: wrap;
  }

  .render-variant-controls {
    left: 10px;
    right: 10px;
    bottom: 10px;
    max-width: none;
  }

  body.is-customize-step .step3-config-panel {
    left: 0;
    right: 0;
    top: 0;
    bottom: auto;
    width: auto;
    max-height: min(62svh, 420px);
    gap: 0;
    padding: 0;
    border-right: 0;
    border-bottom: 1px solid color-mix(in srgb, var(--steel) 18%, rgba(220, 226, 232, .92));
    border-radius: 0 0 8px 8px;
    background: rgba(255, 255, 255, .94);
    transform-origin: top center;
  }

  body.is-customize-step .step3-config-panel.is-collapsed {
    left: 0;
    right: auto;
    top: 0;
    bottom: auto;
    width: 112px;
    max-height: min(62svh, 420px);
    overflow: hidden;
  }

  body.is-customize-step .step3-panel-head {
    gap: 5px;
  }

  body.is-customize-step .step3-panel-mark {
    width: 30px;
    height: 30px;
    font-size: 15px;
  }

  body.is-customize-step .step3-panel-head strong {
    font-size: 15px;
  }

  body.is-customize-step .step3-panel-head small {
    display: none;
  }

  body.is-customize-step .step3-breadcrumb {
    font-size: 10px;
  }

  body.is-customize-step .step3-reset-button {
    min-height: 36px;
    padding-inline: 10px;
  }

  body.is-customize-step .step3-category-list {
    gap: 6px;
  }

  body.is-customize-step .step3-category-summary {
    min-height: 40px;
    padding: 8px 10px;
    font-size: 13px;
  }

  body.is-customize-step .step3-category-icon {
    width: 22px;
    height: 22px;
    font-size: 13px;
  }

  body.is-customize-step .step3-category-body-inner {
    gap: 8px;
    padding: 0 10px 10px 50px;
  }

  body.is-customize-step .step3-option-row {
    gap: 5px;
  }

  body.is-customize-step .step3-option-label > span {
    font-size: 11px;
  }

  body.is-customize-step .step3-option-buttons {
    grid-template-columns: repeat(auto-fit, minmax(64px, 1fr));
    gap: 5px;
    padding: 3px;
  }

  body.is-customize-step .step3-option-buttons button {
    min-height: 38px;
    padding-inline: 9px;
    font-size: 11px;
  }

  body.is-customize-step .step3-view-controls {
    left: auto;
    top: 86px;
    right: 10px;
    bottom: auto;
    width: min(240px, calc(100% - 20px));
    gap: 6px;
    min-width: 0;
    transform: none;
  }

  body.is-customize-step .step3-view-controls > details.step3-levels-menu,
  body.is-customize-step .step3-view-controls > details.step3-views-menu {
    min-width: 0;
    max-width: none;
    flex: 1 1 0;
  }

  body.is-customize-step .step3-view-controls > button {
    min-height: 64px;
    flex-basis: 126px;
  }

  body.is-customize-step .step3-view-controls summary {
    min-height: 38px;
  }

  body.is-customize-step .step3-side-view-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 5px;
  }

  body.is-customize-step .scene-actions {
    justify-content: flex-end;
    max-width: calc(100vw - 20px);
  }

  body.is-customize-step .scene-actions .scene-levels-menu summary {
    min-height: 38px;
    padding-inline: 10px;
    font-size: 12px;
  }

  body.is-customize-step .scene-actions .scene-levels-menu .levels-panel {
    right: 0;
    width: min(280px, calc(100vw - 20px));
  }

  body.is-customize-step .levels-card-grid {
    display: flex;
    gap: 6px;
    overflow-x: auto;
  }

  body.is-customize-step .levels-card-grid button {
    min-width: 108px;
    min-height: 72px;
  }

  .visual-stage.is-expanded .render-variant-controls {
    left: 10px;
    right: 10px;
    bottom: 10px;
    max-width: none;
    transform: none;
  }

  body.is-customize-step .visual-stage.is-expanded .step3-config-panel {
    left: 0;
    right: 0;
    top: 0;
    bottom: auto;
    width: auto;
    max-height: min(62svh, 420px);
    padding: 0;
  }

  body.is-customize-step .visual-stage.is-expanded .step3-config-panel.is-collapsed {
    left: 0;
    right: auto;
    top: 0;
    bottom: auto;
    width: 112px;
    max-height: min(62svh, 420px);
  }

  body.is-customize-step .visual-stage.is-expanded .step3-panel-head {
    top: 0;
    margin: 0;
    padding: 12px;
  }

  .walk-pad {
    left: 10px;
    bottom: 74px;
    grid-template-columns: repeat(3, 46px);
    grid-template-rows: repeat(3, 46px);
    gap: 7px;
  }
}

@media (max-width: 640px) {
  body {
    overscroll-behavior-y: auto;
  }

  .topbar {
    gap: 10px;
  }

  .brand-mark {
    width: 38px;
    height: 38px;
  }

  .preview-toolbar {
    gap: 10px;
    padding: 12px;
  }

  .client-identity {
    padding: 7px 10px 7px 7px;
  }

  .client-identity strong {
    font-size: 15px;
  }

  .client-identity small {
    font-size: 11px;
  }

  .preview-toolbar h2 {
    font-size: 20px;
  }

  .visual-stage {
    min-height: clamp(330px, 58svh, 500px);
  }

  .visual-stage.is-expanded {
    inset: 0;
    border-radius: 0;
  }

  .view-toggle label {
    flex: 1 1 calc(33.333% - 6px);
    min-width: 0;
    padding-inline: 8px;
    text-align: center;
  }

  body.is-customize-step .step3-view-controls {
    left: 10px;
    right: 10px;
    width: auto;
    justify-content: center;
  }

  body.is-customize-step .step3-view-controls > details.step3-levels-menu,
  body.is-customize-step .step3-view-controls > details.step3-views-menu {
    width: 112px;
    flex: 0 1 112px;
  }

  body.is-customize-step .step3-levels-menu .levels-panel,
  body.is-customize-step .step3-views-menu .step3-side-view-grid {
    position: absolute;
    left: 50%;
    top: calc(100% + 8px);
    bottom: auto;
    width: min(370px, calc(100vw - 20px));
    max-width: none;
    margin: 0;
    padding: 0;
    transform: translateX(-50%);
  }

  body.is-customize-step .visual-stage.is-expanded .step3-view-controls {
    left: 10px;
    right: 10px;
    top: auto;
    bottom: 14px;
    width: auto;
    justify-content: center;
    transform: none;
  }

  body.is-customize-step .visual-stage.is-expanded .step3-levels-menu .levels-panel,
  body.is-customize-step .visual-stage.is-expanded .step3-views-menu .step3-side-view-grid {
    top: auto;
    bottom: calc(100% + 8px);
  }

  body.is-customize-step .scene-actions .scene-levels-menu .levels-panel,
  body.is-customize-step .visual-stage.is-expanded .scene-actions .scene-levels-menu .levels-panel {
    left: auto;
    right: 0;
    top: calc(100% + 8px);
    bottom: auto;
    width: min(312px, calc(100vw - 32px));
    max-height: calc(100vh - 96px);
    overflow: auto;
    transform: none;
  }

  body.is-customize-step .levels-panel-options,
  body.is-customize-step .step3-side-view-grid {
    display: flex;
    grid-template-columns: none;
    gap: 6px;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 2px;
    scroll-padding-inline: 2px;
    scroll-snap-type: x proximity;
    scrollbar-width: thin;
  }

  body.is-customize-step .levels-panel-options button,
  body.is-customize-step .step3-side-view-grid button {
    min-width: 0;
    min-height: 82px;
    flex: 0 0 112px;
    scroll-snap-align: start;
  }

  .media-caption {
    align-items: flex-start;
    flex-direction: column;
    top: 10px;
    gap: 3px;
  }

  .media-controls {
    left: 10px;
    right: 10px;
    bottom: 10px;
  }

  .media-viewer.is-plan-view img {
    padding: 78px 8px 20px;
  }

  .media-viewer.is-plan-view .media-controls {
    left: 10px;
    right: 10px;
    top: 10px;
    flex-wrap: wrap;
    align-items: flex-start;
  }

  .plan-floor-control {
    min-width: 0;
    width: min(100%, 270px);
    min-height: 50px;
    padding: 7px 10px 7px 8px;
    grid-template-columns: 30px minmax(0, 1fr) 22px;
    gap: 7px;
  }

  .plan-floor-icon {
    width: 28px;
    height: 28px;
    font-size: 14px;
  }

  .plan-floor-control select {
    font-size: 15px;
  }

  .plan-zoom-control {
    min-height: 50px;
    padding: 6px;
  }

  .plan-zoom-control button {
    width: 40px;
    min-width: 40px;
    height: 40px;
    min-height: 40px;
    font-size: 20px;
  }

  .plan-zoom-control span {
    min-width: 46px;
    font-size: 12px;
  }

  .plan-dimension-target span {
    min-width: 112px;
    padding: 7px 8px;
  }

  .viewer-mode-toggle {
    min-height: 38px;
    padding: 3px;
  }

  .viewer-mode-button {
    min-width: 39px;
    min-height: 30px;
    font-size: 13px;
  }

  .scene-hud {
    left: 10px;
    right: 10px;
    top: 10px;
    align-items: flex-start;
  }

  .model-config-overlay {
    left: 10px;
    right: auto;
    top: 58px;
    width: min(286px, calc(100% - 20px));
    gap: 6px;
    padding: 8px;
  }

  .model-config-head {
    margin: -8px -8px 0;
  }

  .model-config-overlay summary {
    min-height: 38px;
    padding: 8px;
    font-size: 12px;
    white-space: nowrap;
  }

  .model-config-overlay label {
    min-height: 36px;
    padding: 7px 8px;
    font-size: 12px;
    white-space: nowrap;
  }

  .scene-hud > #modeHint {
    max-width: calc(100% - 94px);
    padding: 8px 9px;
    font-size: 12px;
  }

  .tool-button {
    min-height: 38px;
    padding: 0 10px;
  }

  .icon-button {
    width: 38px;
    height: 38px;
  }

  .walk-pad {
    bottom: 88px;
    grid-template-columns: repeat(3, 44px);
    grid-template-rows: repeat(3, 44px);
    gap: 6px;
  }

  .walk-pad button {
    font-size: 18px;
  }

  .visual-stage.is-expanded .walk-pad {
    left: 10px;
    bottom: 10px;
  }

  body.is-customize-step .visual-stage.is-expanded .walk-pad {
    display: grid;
  }

  .render-variant-controls {
    padding: 6px;
  }

  .render-variant-controls button {
    min-height: 34px;
    padding: 0 10px;
    font-size: 12px;
  }

  body.is-customize-step .step3-config-panel {
    max-height: min(62svh, 380px);
    padding: 0;
  }

  body.is-customize-step .step3-config-panel.is-collapsed {
    width: 110px;
    max-height: min(62svh, 380px);
  }

  body.is-customize-step .step3-view-controls {
    top: 86px;
    width: auto;
  }

  body.is-customize-step .step3-view-controls > button,
  body.is-customize-step .step3-view-controls summary {
    min-height: 38px;
    font-size: 11px;
  }

  body.is-customize-step .step3-side-view-grid button {
    min-height: 72px;
    font-size: 11px;
  }

  body.is-customize-step .step3-view-thumb {
    width: 100%;
    height: 100%;
    min-height: 58px;
  }

  body.is-customize-step .step3-side-view-grid .step3-view-thumb {
    height: 100%;
    min-height: 70px;
  }

  body.is-customize-step .visual-stage.is-expanded .step3-config-panel {
    max-height: min(62svh, 380px);
  }

  body.is-customize-step .step3-panel-head .eyebrow {
    display: none;
  }

  body.is-customize-step .step3-breadcrumb {
    gap: 4px;
  }

  body.is-customize-step .step3-category-summary {
    min-height: 40px;
    padding-block: 7px;
  }

  body.is-customize-step .step3-option-buttons button {
    min-height: 38px;
    padding-inline: 8px;
  }

  body.is-customize-step .step3-category-title small {
    display: none;
  }

  .quote-card dl {
    grid-template-columns: 1fr;
  }

  .full-width {
    justify-self: stretch;
    min-width: 0;
    width: 100%;
  }
}

@media (max-width: 520px) {
  .control-panel,
  .quote-card,
  .notes {
    padding: 16px;
  }

  .panel-head h1 {
    font-size: 22px;
  }

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

  .preview-footer > .panel-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .preview-footer {
    grid-template-columns: 1fr;
  }

  .preview-footer > .summary-band,
  .preview-footer > .panel-actions {
    grid-column: 1;
  }

  .preview-footer > .footer-step-nav {
    display: none;
  }

  body.is-build-step .panel-actions {
    grid-template-columns: 1fr 1fr;
    padding-inline: 4px;
  }

  .step-link {
    min-width: 0;
  }

  .step-link,
  .view-toggle label,
  .segmented label {
    min-height: 36px;
    padding-block: 8px;
    font-size: 14px;
  }

  .choice-card {
    min-height: 0;
  }

  .config-variant-controls button {
    min-height: 104px;
  }

  body.is-build-step .visual-stage,
  body.is-customize-step .visual-stage {
    min-height: clamp(540px, 76svh, 680px);
  }

  body.is-embedded .visual-stage {
    height: 470px;
    min-height: 0;
  }

  body.is-embedded.is-build-step .visual-stage,
  body.is-embedded.is-customize-step .visual-stage {
    height: 560px;
    min-height: 0;
  }

  body.is-customize-step .step3-config-panel {
    top: 0;
    bottom: auto;
    max-height: min(62svh, 360px);
  }

  body.is-customize-step .step3-config-panel.is-collapsed {
    top: 0;
    bottom: auto;
    width: 104px;
    max-height: min(62svh, 360px);
  }

  body.is-customize-step .visual-stage.is-expanded .step3-config-panel {
    top: 0;
    bottom: auto;
    max-height: min(62svh, 360px);
  }

  body.is-customize-step .visual-stage.is-expanded .step3-config-panel.is-collapsed {
    top: 0;
    bottom: auto;
    width: 104px;
    max-height: min(62svh, 360px);
  }

  body.is-customize-step .step3-hotspot-label {
    max-width: 0;
  }

  .summary-band {
    justify-content: stretch;
  }
}

body.viewer-expanded.is-embedded .visual-stage.is-expanded,
body.viewer-expanded .visual-stage.is-expanded {
  height: auto;
  min-height: 0;
}

@media (max-width: 860px) {
  .app-shell {
    padding: 8px;
  }

  .configurator {
    gap: 10px;
  }

  .preview-toolbar {
    border-radius: 8px;
  }

  .preview-titlebar {
    gap: 8px;
  }

  .brand-logo {
    width: min(210px, 66vw);
    height: 46px;
  }

  .preview-toolbar h2 {
    overflow-wrap: anywhere;
  }

  .visual-stage {
    min-height: min(620px, 68dvh);
  }

  body.is-customize-step .visual-stage {
    min-height: min(720px, 76dvh);
  }

  .scene-hud {
    gap: 8px;
  }

  .scene-actions {
    max-width: min(100%, 360px);
    gap: 6px;
  }

  .viewer-mode-toggle {
    max-width: 100%;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .viewer-mode-toggle::-webkit-scrollbar {
    display: none;
  }

  .viewer-mode-button {
    flex: 0 0 auto;
  }

  body.is-customize-step .step3-config-panel,
  body.is-customize-step .visual-stage.is-expanded .step3-config-panel {
    left: 8px;
    right: 8px;
    top: 56px;
    width: auto;
    max-height: min(43dvh, 360px);
    border: 1px solid color-mix(in srgb, var(--steel) 16%, rgba(220, 226, 232, .92));
    border-radius: 8px;
    box-shadow: 0 16px 42px rgba(20, 35, 50, .18);
  }

  body.is-customize-step .step3-config-panel.is-collapsed,
  body.is-customize-step .visual-stage.is-expanded .step3-config-panel.is-collapsed {
    left: 8px;
    right: auto;
    top: 56px;
    width: 82px;
    max-height: min(43dvh, 360px);
  }

  body.is-customize-step .step3-panel-head {
    padding: 9px;
  }

  body.is-customize-step .step3-breadcrumb,
  body.is-customize-step .step3-panel-head .eyebrow {
    display: none;
  }

  body.is-customize-step .step3-category-list {
    padding: 8px;
  }

  body.is-customize-step .step3-category-summary {
    grid-template-columns: 4px 28px minmax(0, 1fr) 12px;
    gap: 7px;
  }

  body.is-customize-step .step3-category-body-inner {
    padding: 0 8px 9px 47px;
  }

  body.is-customize-step .step3-config-panel.is-collapsed .step3-category-list {
    padding: 7px;
  }

  body.is-customize-step .step3-config-panel.is-collapsed .step3-category {
    max-height: 46px;
  }

  body.is-customize-step .step3-config-panel.is-collapsed .step3-category-summary {
    min-height: 44px;
    padding: 6px 3px;
  }

  body.is-customize-step .step3-config-panel.is-collapsed .step3-category-title strong {
    display: none;
  }

  body.is-customize-step .step3-option-buttons {
    grid-template-columns: repeat(auto-fit, minmax(72px, 1fr));
  }

  body.is-customize-step .step3-view-controls {
    left: 50%;
    right: auto;
    top: auto;
    bottom: 10px;
    width: min(360px, calc(100% - 20px));
    transform: translateX(-50%);
  }

  body.is-customize-step .step3-view-controls summary {
    min-height: 34px;
    padding-inline: 10px;
  }

  body.is-customize-step .step3-levels-menu .levels-panel,
  body.is-customize-step .step3-views-menu .step3-side-view-grid {
    top: auto;
    bottom: calc(100% + 8px);
    max-height: min(38dvh, 270px);
  }

  body.is-customize-step .levels-switcher {
    width: min(250px, calc(100vw - 28px));
  }

  .loading-badge {
    left: 50%;
    top: 50%;
    right: auto;
    max-width: min(280px, calc(100% - 28px));
    transform: translate(-50%, -50%);
  }

  .preview-footer {
    gap: 8px;
  }
}

@media (max-width: 640px) {
  .app-shell {
    padding: 6px;
  }

  .preview-toolbar {
    padding: 10px;
  }

  .preview-title .eyebrow {
    margin-bottom: 4px;
    font-size: 10px;
  }

  .preview-toolbar h2 {
    font-size: 19px;
  }

  body.is-model-step .preview-area {
    order: 0;
  }

  .control-panel {
    padding: 14px;
  }

  .model-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 9px;
  }

  .choice-card {
    gap: 6px;
    padding: 9px;
  }

  .choice-card strong {
    font-size: 14px;
  }

  .choice-card small {
    font-size: 11px;
  }

  .visual-stage,
  body.is-build-step .visual-stage,
  body.is-customize-step .visual-stage {
    min-height: min(690px, 74dvh);
  }

  body.viewer-expanded .visual-stage.is-expanded {
    min-height: 100dvh;
  }

  .scene-hud {
    left: 8px;
    right: 8px;
    top: 8px;
  }

  .scene-actions {
    width: 100%;
    justify-content: flex-end;
  }

  .tool-button {
    min-height: 34px;
    padding-inline: 9px;
    font-size: 12px;
  }

  .viewer-mode-toggle {
    max-width: calc(100vw - 112px);
  }

  .viewer-mode-button {
    min-width: 38px;
    min-height: 28px;
    padding-inline: 9px;
    font-size: 12px;
  }

  body.is-customize-step .step3-config-panel,
  body.is-customize-step .visual-stage.is-expanded .step3-config-panel {
    top: 54px;
    max-height: min(42dvh, 330px);
  }

  body.is-customize-step .step3-config-panel.is-collapsed,
  body.is-customize-step .visual-stage.is-expanded .step3-config-panel.is-collapsed {
    width: 72px;
    top: 54px;
    max-height: min(42dvh, 330px);
  }

  body.is-customize-step .step3-panel-title {
    gap: 7px;
  }

  body.is-customize-step .step3-panel-mark {
    width: 28px;
    height: 28px;
  }

  body.is-customize-step .step3-collapse-button {
    width: 28px;
    height: 28px;
  }

  body.is-customize-step .step3-category-list {
    gap: 6px;
  }

  body.is-customize-step .step3-category-summary {
    min-height: 38px;
    grid-template-columns: 4px 26px minmax(0, 1fr) 10px;
    padding: 6px 8px;
  }

  body.is-customize-step .step3-category-title strong {
    font-size: 12px;
  }

  body.is-customize-step .step3-category-body-inner {
    padding-left: 43px;
  }

  body.is-customize-step .step3-option-buttons button {
    min-height: 34px;
    font-size: 10px;
  }

  body.is-customize-step .step3-view-controls {
    bottom: 8px;
    width: min(300px, calc(100% - 16px));
    gap: 5px;
  }

  body.is-customize-step .step3-view-controls > details.step3-levels-menu,
  body.is-customize-step .step3-view-controls > details.step3-views-menu {
    flex-basis: 0;
    width: auto;
  }

  body.is-customize-step .step3-view-controls summary {
    min-height: 32px;
    padding-inline: 8px;
    font-size: 11px;
  }

  body.is-customize-step .step3-view-controls summary::before {
    width: 20px;
    height: 20px;
    margin-right: 6px;
  }

  body.is-customize-step .levels-panel-options button,
  body.is-customize-step .step3-side-view-grid button {
    flex-basis: 98px;
    min-height: 72px;
  }

  .walk-pad {
    left: 8px;
    bottom: 74px;
    grid-template-columns: repeat(3, 40px);
    grid-template-rows: repeat(3, 40px);
  }

  .walk-pad button {
    font-size: 16px;
  }

  .visual-stage.is-expanded .walk-pad {
    bottom: 8px;
  }
}

@media (hover: none) and (pointer: coarse) {
  .choice-card:hover,
  .config-variant-controls button:hover,
  .step3-view-controls button:hover,
  .levels-panel-options button:hover {
    transform: none;
  }

  .step3-hotspot-label {
    display: none;
  }

  .step3-hover-label {
    max-width: calc(100vw - 24px);
    white-space: normal;
  }
}

/* Final mobile layout: keep the 3D controls clear of the model and give the
   configuration panel one predictable scroll area. Desktop layout is unchanged. */
@media (max-width: 860px) {
  body.is-customize-step .visual-stage {
    --mobile-stage-gutter: 8px;
    --mobile-toolbar-height: 40px;
  }

  body.is-customize-step .scene-hud {
    top: var(--mobile-stage-gutter);
    left: var(--mobile-stage-gutter);
    right: var(--mobile-stage-gutter);
    min-height: var(--mobile-toolbar-height);
    align-items: flex-start;
  }

  body.is-customize-step .scene-actions {
    width: auto;
    max-width: calc(100% - 8px);
    min-height: var(--mobile-toolbar-height);
    justify-content: flex-end;
    gap: 4px;
  }

  body.is-customize-step .scene-actions .tool-button {
    min-height: var(--mobile-toolbar-height);
    padding-inline: 9px;
  }

  body.is-customize-step .viewer-mode-toggle {
    min-height: var(--mobile-toolbar-height);
    max-width: min(48vw, 220px);
    overflow-x: auto;
    scrollbar-width: none;
  }

  body.is-customize-step .viewer-mode-toggle::-webkit-scrollbar {
    display: none;
  }

  body.is-customize-step .viewer-mode-button {
    min-height: 32px;
    min-width: 38px;
    padding-inline: 8px;
  }

  body.is-customize-step .scene-levels-menu summary {
    min-height: var(--mobile-toolbar-height);
    padding-inline: 9px;
    font-size: 12px;
  }

  body.is-customize-step .step3-view-controls {
    top: var(--mobile-stage-gutter);
    right: auto;
    bottom: auto;
    left: var(--mobile-stage-gutter);
    width: min(38vw, 150px);
    min-width: 0;
    gap: 4px;
    transform: none;
    z-index: 8;
  }

  body.is-customize-step .step3-view-controls > details.step3-views-menu {
    width: 100%;
    min-width: 0;
  }

  body.is-customize-step .step3-view-controls summary {
    min-height: var(--mobile-toolbar-height);
    padding-inline: 9px;
    font-size: 12px;
  }

  body.is-customize-step .step3-config-panel,
  body.is-customize-step .visual-stage.is-expanded .step3-config-panel {
    top: calc(var(--mobile-stage-gutter) + var(--mobile-toolbar-height) + 8px);
    right: var(--mobile-stage-gutter);
    bottom: auto;
    left: var(--mobile-stage-gutter);
    width: auto;
    max-height: min(40dvh, 300px);
    border: 1px solid color-mix(in srgb, var(--steel) 18%, rgba(220, 226, 232, .92));
    border-radius: 8px;
    box-shadow: 0 14px 32px rgba(20, 35, 50, .18);
  }

  body.is-customize-step .step3-config-panel.is-collapsed,
  body.is-customize-step .visual-stage.is-expanded .step3-config-panel.is-collapsed {
    top: calc(var(--mobile-stage-gutter) + var(--mobile-toolbar-height) + 8px);
    right: var(--mobile-stage-gutter);
    left: var(--mobile-stage-gutter);
    width: auto;
    max-height: 54px;
  }

  body.is-customize-step .step3-config-panel .step3-panel-head {
    flex: 0 0 auto;
    padding: 8px 10px;
  }

  body.is-customize-step .step3-config-panel .step3-panel-head .eyebrow,
  body.is-customize-step .step3-config-panel .step3-breadcrumb,
  body.is-customize-step .step3-config-panel .step3-panel-head > small {
    display: none;
  }

  body.is-customize-step .step3-config-panel .step3-panel-title {
    gap: 7px;
  }

  body.is-customize-step .step3-config-panel .step3-panel-mark {
    width: 26px;
    height: 26px;
    border-radius: 6px;
    font-size: 13px;
  }

  body.is-customize-step .step3-config-panel .step3-panel-head strong {
    font-size: 14px;
  }

  body.is-customize-step .step3-config-panel .step3-reset-button {
    min-height: 30px;
    padding-inline: 8px;
    font-size: 11px;
  }

  body.is-customize-step .step3-config-panel .step3-category-list {
    flex: 1 1 auto;
    min-height: 0;
    padding: 7px;
    gap: 5px;
    overflow-y: auto;
    overscroll-behavior: contain;
    touch-action: pan-y;
    -webkit-overflow-scrolling: touch;
  }

  /* Keep category shortcuts visible, but show content only for the active one. */
  body.is-customize-step .step3-config-panel.is-filtered .step3-category:not(.is-step3-active) .step3-category-body {
    display: none;
  }

  body.is-customize-step .step3-config-panel.is-filtered .step3-category:not(.is-step3-active) {
    max-height: 44px;
  }

  body.is-customize-step .step3-config-panel.is-filtered .step3-category:not(.is-step3-active) .step3-category-summary {
    min-height: 42px;
  }

  body.is-customize-step .step3-config-panel.is-filtered .step3-category.is-step3-active {
    max-height: none;
  }

  body.is-customize-step .step3-config-panel.is-collapsed .step3-panel-title > div,
  body.is-customize-step .step3-config-panel.is-collapsed .step3-panel-actions,
  body.is-customize-step .step3-config-panel.is-collapsed .step3-category-title strong,
  body.is-customize-step .step3-config-panel.is-collapsed .step3-category-title small,
  body.is-customize-step .step3-config-panel.is-collapsed .step3-category-chevron,
  body.is-customize-step .step3-config-panel.is-collapsed .step3-category-body {
    display: none;
  }

  body.is-customize-step .step3-config-panel.is-collapsed .step3-panel-head {
    display: none;
  }

  body.is-customize-step .step3-config-panel.is-collapsed .step3-category-list {
    display: flex;
    flex-direction: row;
    align-items: center;
    height: 52px;
    padding: 5px 7px;
    overflow-x: auto;
    overflow-y: hidden;
  }

  body.is-customize-step .step3-config-panel.is-collapsed .step3-category {
    flex: 0 0 42px;
    max-height: 42px;
  }

  body.is-customize-step .step3-config-panel.is-collapsed .step3-category-summary {
    min-height: 42px;
    padding: 5px 3px;
  }

  body.is-customize-step .step3-config-panel.is-collapsed .step3-category-icon {
    width: 26px;
    height: 26px;
  }

  body.is-customize-step .step3-levels-menu .levels-panel,
  body.is-customize-step .step3-views-menu .step3-side-view-grid {
    left: 0;
    right: auto;
    top: calc(100% + 7px);
    bottom: auto;
    width: min(320px, calc(100vw - 16px));
    max-height: min(38dvh, 270px);
    overflow: auto;
    transform: none;
  }

  body.is-customize-step .visual-stage.is-expanded .step3-levels-menu .levels-panel,
  body.is-customize-step .visual-stage.is-expanded .step3-views-menu .step3-side-view-grid {
    top: calc(100% + 7px);
    bottom: auto;
  }
}

@media (max-width: 520px) {
  body.is-customize-step .visual-stage {
    --mobile-toolbar-height: 36px;
  }

  body.is-customize-step .step3-view-controls {
    width: 34vw;
  }

  body.is-customize-step .viewer-mode-toggle {
    max-width: 45vw;
  }

  body.is-customize-step .step3-config-panel,
  body.is-customize-step .visual-stage.is-expanded .step3-config-panel {
    max-height: min(40dvh, 280px);
  }
}
