.floor-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 6px;
  background: #e9eee5;
  border: 1px solid #d9e1d5;
  border-radius: 12px;
}
.floor-tabs button {
  flex: 1 1 135px;
  min-height: 44px;
  background: transparent;
  border-color: transparent;
}
.floor-tabs button[aria-pressed=true] { background: #29483a; color: #fffdf7; }
#floor-status:empty { display: none; }
#floor-content { margin-top: 14px; }
.floor-plan-bar { margin: 0 0 14px; }
.floor-plan-bar .field { min-width: min(220px, 100%); }
.floor-state {
  align-self: end;
  border: 1px solid #e2d3b9;
  padding: 7px 12px;
  border-radius: 100px;
  color: #65491f;
  background: #f8efd9;
  font-weight: 700;
  font-size: .85rem;
}
.floor-state.is-approved { background: #e4efe5; color: #234c37; border-color: #c3d8c8; }
.floor-tools { flex-wrap: wrap; }
.floor-tools button, .floor-inspector button, #floor-content select, .floor-drop { min-height: 44px; }
.floor-board-grid, .floor-seating-grid {
  display: grid;
  grid-template-columns: minmax(0,1fr) minmax(235px,310px);
  gap: 14px;
  align-items: start;
}
.floor-board { min-width: 0; }
.floor-board h2, .floor-inspector h2, .floor-board-grid h2, .floor-seating-grid h2, .floor-reception h2, .floor-bin-list h2 { margin: 0 0 8px; }
.floor-board-head p { margin: 0 0 8px; }
.floor-view-tools {
  display: flex;
  gap: 6px 18px;
  flex-wrap: wrap;
  margin: 8px 0 12px;
  padding: 5px 10px;
  background: #eff2e9;
  border-radius: 8px;
}
.floor-view-tools label { display: flex; align-items: center; gap: 7px; min-height: 44px; }
.floor-view-tools select { width: auto; }
.floor-viewport {
  overflow: auto;
  border: 1px solid #9cae9b;
  border-radius: 9px;
  max-height: min(68vh, 900px);
  background: #f3f4ea;
  overscroll-behavior: contain;
}
.floor-svg { display: block; height: auto; max-width: none; }
.floor-object { cursor: grab; touch-action: none; }
.floor-object:active { cursor: grabbing; }
.floor-svg.is-locked .floor-object { cursor: pointer; touch-action: auto; }
.floor-svg.is-locked .floor-object:not([role]) { cursor: default; }
.floor-object text { fill: #243b30; font-family: system-ui,sans-serif; font-weight: 700; pointer-events: none; }
.floor-shape { fill: var(--floor-object-fill,#e6eddf); stroke: var(--floor-object-stroke,#4c715b); stroke-width: .13; }
.shape-area .floor-shape { fill: var(--floor-object-fill,#f2e7ca); stroke: var(--floor-object-stroke,#8c7346); stroke-dasharray: .25 .14; }
.shape-wall .floor-shape { fill: #52685e; }
.shape-door .floor-shape { fill: none; stroke: #455e53; stroke-width: .23; pointer-events: stroke; }
.shape-plant .floor-shape { fill: var(--floor-object-fill,#c9dfc3); }
.floor-object.is-selected .floor-shape, .floor-object:focus-visible .floor-shape { stroke: #aa7330; stroke-width: .27; }
.floor-object.is-selected text, .floor-object:focus-visible text { fill: #774d18; }
.floor-drawn-chair { fill: #fffdf6; stroke: #5d7867; stroke-width: .11; }
.floor-drawn-chair.is-seated { fill: #78a085; }
.floor-fields { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 8px; }
.floor-fields input { min-width: 0; }
.floor-drop {
  display: grid;
  gap: 5px;
  padding: 14px;
  border: 1px dashed #8da995;
  background: #f2f5ec;
  border-radius: 9px;
  margin: 8px 0;
  cursor: pointer;
  overflow-wrap: anywhere;
}
.floor-drop input { width: 100%; }
.floor-empty { padding: 22px; }
.floor-empty .floor-drop { max-width: 470px; }
.floor-ceremony-scroll { overflow: auto; }
.floor-ceremony-front {
  display: grid;
  grid-template-columns: 1fr 1.3fr 1fr;
  align-items: start;
  gap: 8px;
  padding: 13px 10px;
  margin: 12px auto;
  background: #f5efe3;
  border: 1px solid #e3d9c5;
  border-radius: 9px;
  text-align: center;
  overflow-wrap: anywhere;
}
.floor-ceremony-front ul { list-style: none; padding: 0; margin: 6px 0 0; }
.floor-couple { align-self: center; display: grid; gap: 6px; }
.floor-couple strong { color: #29483a; font-size: 1.12rem; }
.floor-front-label { text-align: center; padding: 12px; font-weight: 700; }
.floor-ceremony-rows { display: grid; gap: 5px; width: max-content; min-width: 100%; padding: 3px 0; }
.floor-ceremony-row {
  display: grid;
  grid-template-columns: 1fr 36px 1fr;
  gap: 6px;
  align-items: center;
  justify-items: center;
}
.floor-ceremony-row > div, .floor-table-seats { display: flex; gap: 4px; }
.floor-ceremony-row > div:first-child { justify-self: end; }
.floor-ceremony-row > div:last-child { justify-self: start; }
.floor-ceremony-row > span { font-size: .82rem; color: #52645b; }
button.floor-seat { width: 44px; height: 44px; padding: 1px; border-radius: 8px; background: #f6f8f2; }
button.floor-seat.is-seated { background: #365d49; color: white; }
button.floor-seat.is-reserved { background: #f3e7cd; color: #755226; }
.floor-legend { display: flex; flex-wrap: wrap; gap: 15px; font-size: .85rem; margin-top: 12px; }
.floor-reception, .floor-bin-list { margin-top: 14px; }
.floor-table-cards { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(240px,100%),1fr)); gap: 10px; }
.floor-table-cards article { border-radius: 9px; padding: 12px; border: 1px solid var(--floor-bin-edge,#d5e0d5); background: var(--floor-bin,#f6f8f1); overflow-wrap: anywhere; }
.floor-table-cards h3 { margin: 0 0 8px; }
.floor-table-cards article.is-selected { border-color: #9e7445; }
.floor-table-seats { flex-wrap: wrap; }
.floor-table-cards ol { margin-bottom: 0; }
.floor-process-list { list-style: none; counter-reset: process; padding: 0; }
.floor-process-list li { counter-increment: process; display: grid; grid-template-columns: auto minmax(0,1fr) auto; align-items: start; gap: 8px; padding: 10px 0; border-top: 1px solid #dde5d9; }
.floor-process-list li::before { content: counter(process); display: grid; place-items: center; min-width: 34px; height: 34px; border-radius: 50%; background: #e8efe3; font-weight: 700; }
.floor-process-list small { display: block; margin-top: 3px; }
.floor-process-list p { overflow-wrap: anywhere; }
#floor-table-editor, #floor-seat-editor { color: #20382d; background: #fffdf8; border: 1px solid #cad6c9; padding: 0; border-radius: 14px; max-height: 88vh; }
#floor-table-editor { width: min(610px, calc(100% - 24px)); }
#floor-seat-editor { width: min(470px, calc(100% - 24px)); }
#floor-table-editor::backdrop, #floor-seat-editor::backdrop { background: #192e25aa; }
.floor-dialog { padding: 16px; }
.floor-dialog h2 { margin: 0; }
.floor-catalog-grid { display: grid; grid-template-columns: repeat(auto-fill,minmax(132px,1fr)); gap: 8px; }
button.floor-catalog-tile { display: grid; justify-items: center; gap: 7px; white-space: normal; background: #f5f7ef; min-height: 112px; }
.floor-catalog-tile svg { display: block; width: 84px; height: 37px; }
.floor-catalog-tile small { color: #425b4b; }
@media(max-width:1180px) {
  .floor-board-grid, .floor-seating-grid { grid-template-columns: minmax(0,1fr); }
  .floor-inspector { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(235px,100%),1fr)); }
}
@media(max-width:600px) {
  .floor-process-list li { grid-template-columns: auto minmax(0,1fr); }
  .floor-process-list .floor-tools { grid-column: 2; }
}
.floor-svg:not(.is-locked) :is(.floor-object,.floor-object *) { touch-action: none; }

.floor-studio { grid-template-columns: minmax(0,1fr) minmax(230px,290px); }
.floor-studio .floor-viewport { max-height: min(67vh, 850px); }
.floor-studio .floor-svg { min-width: 480px; }
.floor-table-picker { display: flex; gap: .5rem; align-items: center; }
.floor-table-picker select { width: auto; max-width: 190px; }
.floor-library-panel h2 { margin: 0; }
.floor-library-panel .floor-catalog-grid {
  grid-template-columns: repeat(2,minmax(0,1fr));
  max-height: 300px;
  overflow-y: auto;
  overscroll-behavior: contain;
  margin: .5rem 0;
}
.floor-library-panel .floor-catalog-tile { min-height: 76px; gap: 2px; padding: 5px; font-size: .84rem; cursor: grab; }
.floor-library-panel .floor-catalog-tile svg { width: 64px; height: 29px; }
.floor-library-panel .floor-catalog-tile small { font-size: .72rem; }
.floor-image-input { display: grid; gap: .25rem; font-weight: 650; }
.floor-image-input input { max-width: 100%; }
.floor-settings summary { cursor: pointer; font-weight: 700; }
.floor-settings form { margin-top: .75rem; }
.floor-draw-tools { margin-bottom: .55rem; }
.floor-draw-tools [aria-pressed=true],.floor-roster [aria-pressed=true] { background: #29483a; color: white; }
.floor-drawing-hint { margin: 0 0 .5rem; }
.floor-viewport.is-drawing .floor-svg,.floor-viewport.is-drawing .floor-object { cursor: crosshair; }
.floor-object .floor-map-seat { font-size: .57px; paint-order: stroke; stroke: #fffdf7; stroke-width: .14px; }
.floor-symbol { fill: none; stroke: #324c40; stroke-width: .12; pointer-events: none; }
.floor-legend i { display: inline-block; width: .65rem; height: .65rem; border-radius: 50%; margin-right: .3rem; }
.floor-counter { display: flex; flex-wrap: wrap; align-items: baseline; gap: .4rem 1rem; padding: .6rem; border-radius: .5rem; background: #e9eee5; }
.floor-ceremony-row { grid-template-columns: 1fr var(--aisle) 1fr; padding-bottom: var(--seat-depth); }
.floor-ceremony-row > div > span { position: relative; top: var(--seat-offset); }
.floor-ceremony-row button.floor-seat,.floor-table-seats button.floor-seat { width: 75px; font-size: .73rem; line-height: 1.15; overflow-wrap: anywhere; }
.floor-roster-list { display: flex; flex-wrap: wrap; gap: .35rem; max-height: 235px; overflow: auto; }
.floor-roster-list button { text-align: left; min-height: 38px; }
.floor-ceremony-front [data-floor-stand] { display: grid; gap: .3rem; align-self: stretch; align-content: start; border-radius: .5rem; padding: .35rem; border: 1px dashed #9dae9f; }
.floor-ceremony-front [data-floor-stand] button { white-space: normal; font-size: .76rem; }
@media(max-width:960px) {
  .floor-studio { grid-template-columns: minmax(0,1fr) minmax(200px,234px); }
  .floor-studio .floor-inspector { display: block; }
  .floor-studio .floor-inspector > * + * { margin-top: .6rem; }
}
@media(max-width:680px) {
  .floor-studio { grid-template-columns: minmax(0,1fr); }
  .floor-library-panel .floor-catalog-grid { grid-template-columns: repeat(3,minmax(0,1fr)); }
}
.floor-object.shape-area .floor-shape { fill-opacity: .72; }
.floor-catalog-tile .shape-round .floor-shape { stroke-width: .15; }

.project-step { display: inline-flex; gap: .4rem; align-items: center; }
.project-step button { min-width: 43px; min-height: 43px; padding: .15rem .65rem; font-size: 1.65rem; line-height: 1; }
.project-step button:disabled { opacity: .45; }
.floor-viewport { container-type: inline-size; }
.floor-viewport .floor-svg {
  width: calc(min(100cqw, var(--floor-fit-height,58svh) * var(--floor-ratio,1)) * var(--floor-zoom,1));
  min-width: 0;
  margin-inline: auto;
}
.floor-view-tools input[type=number] { width: 5rem; }
.floor-view-tools > span { margin-left: -.75rem; align-self: center; }
.floor-view-tools button[aria-pressed=true] { background: #29483a; color: #fff; }
.floor-wall-line { fill: none; stroke: var(--floor-object-stroke,#274237); stroke-width: 3.5px; stroke-linecap: round; vector-effect: non-scaling-stroke; pointer-events: none; }
.floor-wall-hit { pointer-events: all; }
.floor-resize-handle { fill: #fffcf2; stroke: #36311f; stroke-width: 1.5px; vector-effect: non-scaling-stroke; cursor: nwse-resize; }
.shape-wall .floor-resize-handle { cursor: ew-resize; }
.floor-icon { pointer-events: none; overflow: visible; }
.floor-icon path { fill: none; stroke: var(--floor-object-stroke,#324c40); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.floor-symbol { stroke: var(--floor-object-stroke,#324c40); stroke-width: 1.35px; vector-effect: non-scaling-stroke; }
.floor-label-sample { font-size: 2.65px; fill: #29483a; }
.floor-electrical-key { padding: .55rem 0 0; border-top: 1px solid #e0e8db; margin-top: .75rem; }
.floor-electrical-key h3 { margin: 0; font-size: .88rem; }
.floor-electrical-key .floor-legend span { display: inline-flex; gap: .35rem; align-items: center; }
.floor-electrical-key svg { width: 26px; height: 24px; }
.floor-ceremony-row > div > span { transform: rotate(var(--seat-angle,0deg)); transform-origin: center; }
.floor-ceremony-row > div { gap: .45rem; }
#floor-reference-scale { width:min(480px,calc(100% - 24px)); }
#floor-reference-scale::backdrop { background:#253b2b70; }
