:root {
  --accent: #f05a00;
  --accent-dark: #c64a00;
  --ink: #262728;
  --muted: #6c7278;
  --line: #d9dee2;
  --soft: #f4f5f5;
  --panel: #ffffff;
  --stage: #e6e1dc;
  --good: #00a96b;
  --dark-control: #3d4145;
  font-family: Arial, Helvetica, sans-serif;
  color: var(--ink);
}

[hidden] {
  display: none !important;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  background: #f0f2f3;
}

body.modal-open {
  overflow: hidden;
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

.app-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.site-header {
  background: #fff;
  border-bottom: 1px solid var(--line);
  flex: 0 0 auto;
}

.utility-nav {
  height: 36px;
  display: flex;
  align-items: stretch;
  border-bottom: 1px solid #e8ecef;
}

.utility-nav a {
  display: flex;
  align-items: center;
  padding: 0 28px;
  color: #171717;
  text-decoration: none;
  font-size: 14px;
  font-weight: 700;
  border-right: 1px solid #e8ecef;
}

.utility-nav a.active {
  background: #f8f8f8;
}

.brand-row {
  height: 48px;
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 18px;
  padding: 0 26px;
}

.menu-button {
  width: max-content;
  display: inline-grid;
  grid-template-columns: 18px auto;
  grid-template-rows: repeat(3, 2px);
  align-items: center;
  column-gap: 8px;
  row-gap: 4px;
  border: 0;
  background: transparent;
  color: #222;
}

.menu-button::after {
  content: "Menü";
  grid-column: 2;
  grid-row: 1 / span 3;
  font-size: 20px;
}

.menu-button span {
  grid-column: 1;
  width: 16px;
  height: 2px;
  display: block;
  background: #222;
}

.configurator {
  height: calc(100vh - 84px);
  min-height: 620px;
  flex: 1 1 auto;
  display: grid;
  grid-template-columns: 340px minmax(0, 1fr);
  overflow: hidden;
}

.config-panel {
  min-height: 0;
  display: grid;
  grid-template-rows: auto auto auto minmax(0, 1fr);
  background: var(--panel);
  border-right: 1px solid #cfd5da;
}

.product-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  border-bottom: 1px solid #dde1e4;
}

.product-button {
  min-height: 82px;
  display: grid;
  place-items: center;
  gap: 3px;
  border: 0;
  border-right: 1px solid #e5e8eb;
  background: #fff;
  color: #4c5054;
  font-size: 12px;
  font-weight: 800;
  position: relative;
}

.product-button svg {
  width: 50px;
  height: 36px;
  stroke: currentColor;
  fill: none;
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.product-button.selected {
  color: var(--accent);
}

.product-button.selected::after,
.step-tab.selected::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 0;
  height: 3px;
  background: var(--accent);
}

.step-tabs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-bottom: 1px solid #dde1e4;
}

.step-tab {
  min-height: 48px;
  position: relative;
  border: 0;
  border-right: 1px solid #e7eaed;
  background: #fff;
  color: #3e4245;
  display: grid;
  place-items: center;
  gap: 2px;
  font-size: 12px;
}

.step-icon {
  font-size: 17px;
  line-height: 1;
}

.step-tab.selected {
  color: var(--accent);
}

.workflow-status-note {
  min-height: 34px;
  display: flex;
  align-items: center;
  padding: 7px 18px;
  border-bottom: 1px solid #dde1e4;
  background: #fff7f1;
  color: #8c3d05;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.2;
}

.panel-scroll {
  min-height: 0;
  overflow: auto;
  padding: 14px 18px 64px;
}

.step-panel {
  display: none;
}

.step-panel.active {
  display: block;
}

h2,
h3 {
  margin: 0;
  font-weight: 800;
  color: var(--accent);
}

h2 {
  font-size: 17px;
  padding-bottom: 6px;
  border-bottom: 2px solid var(--accent);
}

h3 {
  margin-top: 18px;
  font-size: 14px;
}

.hint {
  color: #60676f;
  font-size: 12px;
  line-height: 1.4;
  margin: 8px 0 12px;
}

.option-grid {
  display: grid;
  gap: 7px;
  margin-top: 9px;
}

.option-grid.two {
  grid-template-columns: 1fr 1fr;
}

.option-grid.three {
  grid-template-columns: repeat(3, 1fr);
}

.image-option,
.tile-option {
  min-height: 84px;
  border: 1px solid var(--line);
  background: #fbfbfb;
  color: #2e3337;
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 6px;
  text-align: center;
  padding: 7px;
}

.image-option.selected,
.tile-option.selected,
.image-option:hover,
.tile-option:hover {
  border-color: #1db285;
  box-shadow: inset 0 0 0 1px rgba(29, 178, 133, 0.25);
}

.image-option strong,
.tile-option strong {
  font-size: 12px;
}

.tile-option small {
  color: var(--muted);
  font-weight: 700;
}

.mini-scene {
  width: 68px;
  height: 42px;
  display: block;
  position: relative;
  background: linear-gradient(160deg, #eff6f9, #d7e3eb);
  overflow: hidden;
}

.mini-scene::before,
.mini-scene::after {
  content: "";
  position: absolute;
}

.mini-scene::before {
  left: 14px;
  right: 10px;
  top: 14px;
  height: 8px;
  background: #303638;
  transform: skewY(-12deg);
}

.mini-scene::after {
  left: 20px;
  top: 24px;
  width: 42px;
  height: 22px;
  border-left: 4px solid #303638;
  border-right: 4px solid #303638;
}

.mini-scene.wallbound {
  background: linear-gradient(90deg, #eef2f4 0 36%, #d3d9dd 36% 41%, #eef6f9 41%);
}

.dimension-list {
  display: grid;
  gap: 7px;
  margin-top: 8px;
}

.project-grid {
  display: grid;
  gap: 5px;
  margin: 8px 0 12px;
}

.number-row,
.select-row,
.text-row,
.range-row,
.toggle-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid #edf0f2;
  padding: 7px 0;
  transition: background 140ms ease, border-color 140ms ease;
}

.number-row:focus-within,
.select-row:focus-within,
.text-row:focus-within,
.range-row:focus-within,
.toggle-row:focus-within {
  background: #fbfdfd;
  border-bottom-color: #cdd7da;
}

.number-row.compact {
  margin-top: 10px;
}

.number-row strong,
.select-row strong,
.text-row strong,
.range-row strong {
  display: block;
  font-size: 12px;
  line-height: 1.18;
}

.number-row small,
.select-row small,
.text-row small,
.range-row small {
  display: block;
  color: var(--muted);
  font-size: 11px;
  margin-top: 2px;
}

.text-row input {
  width: 142px;
  min-width: 0;
  height: 34px;
  border: 1px solid var(--line);
  padding: 0 10px;
  background: #fff;
}

.text-row input:focus,
.number-control:focus-within,
.select-row select:focus {
  outline: 2px solid rgba(29, 178, 133, 0.18);
  outline-offset: 1px;
  border-color: rgba(29, 178, 133, 0.58);
}

.number-control {
  height: 38px;
  min-width: 0;
  width: 100%;
  display: grid;
  grid-template-columns: minmax(50px, 1fr) auto 34px 34px;
  align-items: stretch;
  border: 1px solid var(--line);
  background: #fff;
}

.number-control.single {
  grid-template-columns: minmax(76px, 1fr) auto;
}

.number-control input {
  width: 100%;
  min-width: 0;
  border: 0;
  padding: 0 10px;
}

.number-control em {
  display: flex;
  align-items: center;
  color: #4a5055;
  font-style: normal;
  padding-right: 8px;
}

.number-control button {
  border: 0;
  border-left: 1px solid var(--line);
  background: #f8f9fa;
  font-size: 20px;
  color: #384048;
}

.swatch-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 7px;
  margin-top: 8px;
}

.swatch {
  min-height: 54px;
  border: 1px solid var(--line);
  background: #fff;
  display: grid;
  justify-items: center;
  gap: 4px;
  padding: 7px 5px;
  font-size: 11px;
  font-weight: 700;
}

.swatch span {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--swatch);
  border: 1px solid #b7bdc2;
}

.swatch.selected {
  border-color: #1db285;
}

.roof-sample {
  width: 46px;
  height: 32px;
  display: block;
  transform: skewX(-13deg);
  border: 1px solid rgba(110, 126, 135, 0.28);
}

.roof-sample.clear {
  background: linear-gradient(110deg, rgba(141, 203, 218, 0.35), rgba(255, 255, 255, 0.78), rgba(141, 203, 218, 0.28));
}

.roof-sample.milk {
  background: linear-gradient(110deg, rgba(244, 252, 250, 0.9), rgba(218, 236, 230, 0.75));
}

.roof-sample.poly {
  background: repeating-linear-gradient(100deg, rgba(166, 214, 198, 0.55) 0 5px, rgba(255, 255, 255, 0.7) 5px 9px);
}

.roof-sample.metal {
  background: repeating-linear-gradient(90deg, #c6ccd1 0 6px, #f2f3f3 6px 12px);
}

.segmented-control {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  margin-top: 8px;
  border: 1px solid var(--line);
}

.segmented-control button {
  flex: 1 1 92px;
  min-height: 34px;
  border: 0;
  border-right: 1px solid var(--line);
  background: #f6f7f7;
  color: #3a4045;
  font-weight: 700;
}

.segmented-control button:last-child {
  border-right: 0;
}

.segmented-control button.selected {
  background: #fff;
  color: var(--accent);
  box-shadow: inset 0 -3px 0 var(--accent);
}

.carport-system-control[hidden] {
  display: none;
}

.bridge-control {
  border-top: 1px solid var(--line);
  display: grid;
  gap: 6px;
  margin-top: 10px;
  padding-top: 10px;
}

.bridge-control[hidden],
#glassThicknessRow[hidden] {
  display: none;
}

.bridge-control h4 {
  font-size: 13px;
  margin: 0;
}

.toggle-stack {
  display: grid;
  gap: 0;
}

.range-row {
  grid-template-columns: 1fr;
}

.range-row > span {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

.range-row input {
  width: 100%;
  accent-color: var(--accent);
}

.toggle-row {
  grid-template-columns: auto 1fr;
  justify-content: start;
  font-weight: 700;
}

.toggle-row input {
  width: 18px;
  height: 18px;
  accent-color: var(--accent);
}

.list-options {
  display: grid;
  gap: 6px;
  margin-top: 8px;
}

.select-row select {
  width: 176px;
  height: 38px;
  border: 1px solid var(--line);
  background: #fff;
  padding: 0 8px;
}

.list-options .select-row,
.list-options .number-row.compact {
  grid-template-columns: 1fr;
  align-items: stretch;
  gap: 7px;
}

.list-options .select-row select,
.list-options .number-row.compact .number-control {
  width: 100%;
}

.select-row select:disabled,
.toggle-row input:disabled {
  opacity: 0.52;
}

.field-buttons {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 10px;
}

.field-buttons button {
  min-height: 42px;
  border: 1px solid var(--line);
  background: #fff;
  font-weight: 700;
}

.field-buttons button.selected {
  border-color: var(--accent);
  color: var(--accent);
  box-shadow: inset 0 0 0 1px var(--accent);
}

.viewer {
  min-width: 0;
  min-height: 0;
  position: relative;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto auto;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(255, 255, 255, 0) 42%),
    linear-gradient(135deg, #f7f8f7 0%, #e7ecec 54%, #d6dddd 100%);
}

.viewer-topbar {
  min-width: 0;
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 9px 22px;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid rgba(197, 204, 209, 0.76);
  box-shadow: 0 6px 18px rgba(30, 39, 44, 0.05);
  z-index: 2;
}

.viewer-topbar > div {
  min-width: 0;
}

.viewer-topbar strong {
  color: var(--accent);
  display: block;
  margin-bottom: 2px;
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.viewer-topbar span {
  margin-left: 0;
  color: #25282b;
  font-size: 17px;
  font-weight: 800;
}

.viewer-actions {
  min-width: 0;
  max-width: 100%;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 3px;
  border: 1px solid rgba(210, 216, 220, 0.82);
  background: rgba(247, 249, 249, 0.88);
}

.viewer-actions button,
.bottom-tools button {
  min-height: 34px;
  border: 1px solid rgba(185, 193, 198, 0.72);
  background: rgba(255, 255, 255, 0.94);
  color: #3d4247;
  padding: 0 12px;
  font-size: 12px;
  font-weight: 700;
  box-shadow: 0 5px 14px rgba(34, 42, 48, 0.05);
}

.viewer-actions button[aria-pressed="true"],
.bottom-tools button:last-child {
  color: #fff;
  background: var(--dark-control);
}

.bottom-tools #prepareOfferButton {
  color: #fff;
  background: var(--accent);
  border-color: var(--accent);
}

.bottom-tools #prepareOfferButton:hover {
  background: var(--accent-dark);
}

.canvas-wrap {
  min-height: 0;
  position: relative;
  overflow: hidden;
  background: #eef1f1;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.92),
    inset 0 -1px 0 rgba(91, 105, 112, 0.2);
}

#previewCanvas {
  width: 100%;
  height: 100%;
  display: block;
  cursor: grab;
}

#previewCanvas.dragging {
  cursor: grabbing;
}

.canvas-badge {
  position: absolute;
  right: 26px;
  bottom: 22px;
  max-width: min(360px, calc(100% - 52px));
  padding: 8px 11px;
  color: #273038;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(173, 184, 190, 0.72);
  font-size: 11px;
  font-weight: 700;
  box-shadow: 0 12px 30px rgba(30, 39, 44, 0.1);
}

.offer-status-panel {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(330px, auto) auto;
  align-items: center;
  gap: 14px;
  padding: 13px 22px;
  border-top: 1px solid rgba(197, 204, 209, 0.76);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 -8px 22px rgba(30, 39, 44, 0.05);
  z-index: 2;
}

.offer-status-copy {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.offer-status-copy span {
  color: var(--accent);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.offer-status-copy strong {
  color: #22272b;
  font-size: 16px;
  line-height: 1.12;
}

.offer-status-copy small {
  color: #5f6870;
  font-size: 12px;
  line-height: 1.32;
}

.offer-status-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(72px, 1fr));
  gap: 7px;
}

.offer-status-metrics div {
  min-width: 0;
  padding: 7px 9px;
  border: 1px solid rgba(210, 216, 220, 0.82);
  background: #f8faf9;
}

.offer-status-metrics span {
  display: block;
  color: #687078;
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
}

.offer-status-metrics strong {
  display: block;
  margin-top: 2px;
  color: #22272b;
  font-size: 12px;
  line-height: 1.14;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.offer-status-panel button {
  min-height: 42px;
  border: 1px solid var(--accent);
  background: var(--accent);
  color: #fff;
  padding: 0 18px;
  font-size: 13px;
  font-weight: 800;
  white-space: nowrap;
  box-shadow: 0 10px 20px rgba(240, 90, 0, 0.2);
}

.offer-status-panel button:hover {
  background: var(--accent-dark);
}

.bottom-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 0 22px 16px;
  border-top: 1px solid rgba(232, 235, 237, 0.92);
  background: rgba(255, 255, 255, 0.96);
  z-index: 2;
}

.bom-dialog {
  position: fixed;
  inset: 0;
  z-index: 30;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(25, 27, 28, 0.48);
}

.bom-dialog[hidden] {
  display: none;
}

.bom-sheet {
  width: min(1040px, 100%);
  max-height: min(820px, calc(100vh - 48px));
  overflow: auto;
  background: #fff;
  border: 1px solid rgba(166, 173, 179, 0.8);
  box-shadow: 0 26px 80px rgba(0, 0, 0, 0.24);
}

.bom-header,
.bom-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 22px;
  border-bottom: 1px solid var(--line);
}

.bom-header h2 {
  padding-bottom: 0;
  border-bottom: 0;
}

.bom-footer {
  justify-content: flex-end;
  flex-wrap: wrap;
  border-top: 1px solid var(--line);
  border-bottom: 0;
  position: sticky;
  bottom: 0;
  background: rgba(255, 255, 255, 0.96);
}

.bom-footer button,
.icon-button {
  min-height: 38px;
  border: 1px solid var(--line);
  background: #fff;
  color: #30363b;
  font-weight: 800;
  padding: 0 14px;
}

.bom-footer button:last-child {
  color: #fff;
  background: var(--accent);
  border-color: var(--accent);
}

.bom-footer button:last-child:hover {
  background: var(--accent-dark);
}

.bom-footer button[id*="Drawing"] {
  color: var(--accent);
  background: #f8fbfa;
  border-color: rgba(29, 178, 133, 0.35);
}

.icon-button {
  width: 40px;
  padding: 0;
  font-size: 26px;
  line-height: 1;
}

.section-kicker {
  margin: 0 0 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.bom-summary {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  padding: 14px 22px 8px;
}

.bom-summary div {
  min-height: 62px;
  padding: 10px;
  background: #f5f7f7;
  border-left: 3px solid var(--accent);
}

.bom-summary div.status-bereit {
  border-left-color: #1db285;
  background: #f1faf7;
}

.bom-summary div.status-prüfen {
  border-left-color: #f2a100;
  background: #fff8e8;
}

.bom-summary span {
  display: block;
  color: var(--muted);
  font-size: 12px;
}

.bom-summary strong {
  display: block;
  margin-top: 5px;
  font-size: 15px;
  line-height: 1.18;
}

.handover-panel {
  margin: 4px 22px 8px;
  padding: 12px;
  border: 1px solid var(--line);
  background: #fbfcfc;
}

.handover-route {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.handover-route div {
  min-height: 52px;
  padding: 9px;
  background: #fff;
  border-left: 3px solid #1db285;
}

.handover-route span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.handover-route strong {
  display: block;
  margin-top: 5px;
  font-size: 13px;
  line-height: 1.18;
  overflow-wrap: anywhere;
}

.bom-notices {
  display: grid;
  gap: 8px;
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
}

.bom-notices li {
  padding: 9px 10px;
  border-left: 3px solid #1db285;
  background: #f2faf7;
  color: #283331;
  font-size: 13px;
  line-height: 1.35;
}

.bom-notices li.warn {
  border-color: #f2a100;
  background: #fff8e8;
}

.bom-notices li.danger {
  border-color: #d64545;
  background: #fff0f0;
}

.drawing-spec-panel {
  display: grid;
  gap: 8px;
  margin: 12px 22px 8px;
  padding: 12px;
  border: 1px solid var(--line);
  background: #f8fafb;
}

.drawing-spec-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.drawing-spec-header span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.drawing-spec-header strong {
  color: var(--accent);
  font-size: 13px;
}

.drawing-spec-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.drawing-spec-card {
  min-height: 70px;
  padding: 9px;
  border-left: 3px solid var(--accent);
  background: #fff;
}

.drawing-spec-card span,
.drawing-spec-card small {
  display: block;
  min-width: 0;
}

.drawing-spec-card span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.drawing-spec-card strong {
  display: block;
  margin-top: 6px;
  color: var(--ink);
  font-size: 14px;
  line-height: 1.25;
}

.drawing-spec-card small {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.3;
}

.offer-drawing-preview {
  max-height: 320px;
  overflow: auto;
  border: 1px solid var(--line);
  background: #fff;
}

.internal-only {
  display: none !important;
}

.offer-drawing-preview svg {
  display: block;
  width: 100%;
  min-width: 820px;
  height: auto;
}

.bom-table-wrap {
  padding: 10px 22px 14px;
  overflow-x: auto;
}

.bom-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 640px;
}

.bom-table th,
.bom-table td {
  padding: 9px 8px;
  border-bottom: 1px solid #e8ecef;
  text-align: left;
  vertical-align: top;
}

.bom-table th {
  color: var(--accent);
  font-size: 12px;
  text-transform: uppercase;
}

.bom-table .bom-group-row th {
  padding: 12px 8px 7px;
  background: #f6f8f8;
  color: #3f4649;
  border-bottom: 1px solid #dfe5e8;
  font-size: 12px;
  letter-spacing: 0;
  text-transform: none;
}

.handover-json {
  margin: 0 22px 18px;
  border: 1px solid var(--line);
  background: #f8f9fa;
}

.handover-json summary {
  cursor: pointer;
  padding: 12px;
  font-weight: 800;
}

.handover-json pre {
  max-height: 260px;
  overflow: auto;
  margin: 0;
  padding: 12px;
  border-top: 1px solid var(--line);
  font-size: 12px;
}

@media (max-width: 760px) {
  .utility-nav {
    overflow-x: auto;
  }

  .brand-row {
    min-height: 48px;
    grid-template-columns: auto 1fr;
  }

  .configurator {
    height: auto;
    min-height: 0;
    grid-template-columns: 1fr;
    grid-template-rows: auto minmax(520px, 1fr);
    overflow: visible;
  }

  .config-panel {
    max-height: none;
  }

  .panel-scroll {
    max-height: 520px;
  }

  .viewer {
    min-height: 620px;
  }

  .viewer-topbar {
    height: auto;
    min-height: 62px;
    align-items: flex-start;
    flex-direction: column;
    padding: 14px 18px;
  }

  .viewer-actions {
    width: 100%;
    align-self: stretch;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    overflow-x: visible;
    gap: 8px;
    padding-bottom: 3px;
  }

  .viewer-actions button {
    min-width: 0;
    padding: 0 10px;
    white-space: normal;
    line-height: 1.12;
  }

  .offer-status-panel {
    grid-template-columns: 1fr;
    align-items: stretch;
    padding: 13px 18px;
  }

  .offer-status-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .offer-status-panel button {
    width: 100%;
  }

  .bottom-tools {
    padding: 0 18px 16px;
  }

  .bom-dialog {
    padding: 12px;
  }

  .bom-summary {
    grid-template-columns: 1fr 1fr;
  }

  .handover-route,
  .drawing-spec-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  html,
  body {
    overflow-x: hidden;
  }

  .utility-nav {
    overflow-x: auto;
    scrollbar-width: thin;
  }

  .utility-nav a {
    min-width: 0;
    flex: 0 0 auto;
    justify-content: center;
    padding: 0 18px;
    white-space: nowrap;
  }

  .configurator,
  .config-panel,
  .viewer,
  .product-strip,
  .step-tabs {
    width: 100vw;
    max-width: 100vw;
  }

  .brand-row {
    padding: 0 16px;
  }

  .product-button {
    min-height: 78px;
    font-size: 11px;
  }

  .product-button svg {
    width: 44px;
  }

  .step-tab {
    font-size: 11px;
  }

  .panel-scroll {
    padding: 16px 14px 70px;
  }

  .option-grid.three {
    grid-template-columns: repeat(2, 1fr);
  }

  .number-row,
  .select-row,
  .text-row {
    grid-template-columns: 1fr;
  }

  .number-control,
  .select-row select,
  .text-row input {
    width: 100%;
  }

  .swatch-row {
    grid-template-columns: 1fr;
  }

  .bom-summary,
  .drawing-spec-grid {
    grid-template-columns: 1fr;
  }

  .bom-dialog {
    padding: 10px;
  }

  .bom-sheet {
    max-height: calc(100vh - 20px);
  }

  .bom-header,
  .bom-footer {
    padding: 14px 16px;
  }

  .bom-footer {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }

  .bom-footer button:last-child {
    grid-column: 1 / -1;
  }

  .bom-footer button {
    width: 100%;
    min-width: 0;
    padding: 0 8px;
    white-space: normal;
    line-height: 1.12;
  }

  .handover-route {
    grid-template-columns: 1fr;
  }

  .drawing-spec-panel,
  .handover-panel,
  .handover-json {
    margin-left: 16px;
    margin-right: 16px;
  }

  .bom-summary,
  .bom-table-wrap {
    padding-left: 16px;
    padding-right: 16px;
  }
}
