/* VenueSync Interactive SVG Floor Plan & Seating Styles */
.floorplan-wrapper {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  overflow: hidden;
  position: relative;
  user-select: none;
}

.floorplan-toolbar {
  padding: 12px 18px;
  background: var(--bg-card);
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.floorplan-legend {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 0.8rem;
  color: var(--text-muted);
}
.legend-item {
  display: flex;
  align-items: center;
  gap: 6px;
}
.legend-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  display: inline-block;
}
.dot-avail { background: #2ECC71; }
.dot-selected { background: var(--accent-primary); box-shadow: 0 0 8px var(--accent-primary); }
.dot-reserved { background: #E74C3C; }
.dot-pending { background: #E59A3C; box-shadow: 0 0 6px #E59A3C; }
.dot-seated { background: #4A90E2; }
.dot-blocked { background: #A55EEA; box-shadow: 0 0 6px #A55EEA; }
.dot-ineligible { background: #554D45; }

.floorplan-svg-container {
  width: 100%;
  min-height: 560px;
  max-height: 82vh;
  height: 680px;
  overflow: auto;
  position: relative;
  background: #110F0E;
  display: flex;
  justify-content: center;
  align-items: center;
}

.floorplan-svg {
  width: 100%;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
  display: block;
  margin: auto;
}

/* Seating Units (Tables, Bars, Couches, Obstacles) */
.seating-unit-group {
  cursor: grab;
  touch-action: none;
  transition: opacity 0.2s, stroke-width 0.2s;
}
.seating-unit-group.is-dragging {
  cursor: grabbing !important;
  opacity: 0.92;
}
.seating-unit-group.is-dragging .seating-unit-body {
  stroke: var(--accent-primary) !important;
  stroke-width: 3.5 !important;
  filter: drop-shadow(0 0 12px rgba(229, 154, 60, 0.5));
}
.seating-unit-body {
  fill: #221E1A;
  stroke: #4A4036;
  stroke-width: 2;
  transition: stroke 0.2s, stroke-width 0.2s;
}
.seating-unit-body.unit-obstacle {
  fill: #2B2621;
  stroke: #665C50;
  stroke-dasharray: 6 3;
}
.seating-unit-body.unit-standalone-chair {
  fill: #1A221C;
  stroke: #2ECC71;
  stroke-width: 1.5;
}
.seating-unit-group:hover .seating-unit-body {
  stroke: var(--accent-primary);
}
/* Unit Drag-Resize Handles in Builder Mode */
.unit-resize-handles {
  opacity: 0.85;
  transition: opacity 0.2s;
}
.seating-unit-group:hover .unit-resize-handles,
.seating-unit-group.is-resizing .unit-resize-handles {
  opacity: 1;
}
.unit-resize-handle {
  fill: var(--accent-primary, #E59A3C);
  stroke: #110F0E;
  stroke-width: 1.5;
  touch-action: none;
  transition: fill 0.15s, transform 0.15s;
}
.unit-resize-handle:hover,
.unit-resize-handle.is-resizing {
  fill: #ffffff !important;
  stroke: var(--accent-primary, #E59A3C) !important;
  stroke-width: 2 !important;
  filter: drop-shadow(0 0 6px var(--accent-primary, #E59A3C));
}
.seating-unit-group.is-resizing {
  opacity: 0.96;
}
.seating-unit-label {
  fill: var(--text-muted);
  font-family: var(--font-heading);
  font-size: 13px;
  font-weight: 700;
  text-anchor: middle;
  dominant-baseline: central;
  pointer-events: none;
}

/* Individual Selectable Seats */
.seat-node.builder-seat {
  cursor: grab !important;
  touch-action: none;
}
.seat-node.builder-seat:hover .seat-circle {
  stroke: var(--accent-secondary) !important;
  stroke-width: 3.5 !important;
  filter: drop-shadow(0 0 8px var(--accent-secondary));
}
.seat-node.is-dragging-seat {
  cursor: grabbing !important;
}
.seat-node.is-dragging-seat .seat-circle {
  stroke: #ffffff !important;
  stroke-width: 4 !important;
  filter: drop-shadow(0 0 12px #ffffff);
}
.seat-circle {
  cursor: pointer;
  transition: all 0.2s;
  stroke-width: 2.5;
}
/* Available */
.seat-circle.status-available {
  fill: #1A3826;
  stroke: #2ECC71;
}
.seat-circle.status-available:hover {
  fill: #2ECC71;
  stroke: #fff;
  stroke-width: 3.5px;
  filter: drop-shadow(0 0 8px #2ECC71);
}
/* Selected by User */
.seat-circle.status-selected {
  fill: var(--accent-primary);
  stroke: #fff;
  filter: drop-shadow(0 0 6px var(--accent-primary));
}
/* Reserved / Locked */
.seat-circle.status-reserved {
  fill: #3D1C1C;
  stroke: #E74C3C;
  stroke-width: 2.5px;
  cursor: pointer;
  opacity: 0.95;
}
.seat-circle.status-reserved:hover {
  fill: #E74C3C;
  stroke: #fff;
  filter: drop-shadow(0 0 8px #E74C3C);
}

/* Pending Confirmation */
.seat-circle.status-pending {
  fill: #3D2B14;
  stroke: #E59A3C;
  stroke-width: 2.5px;
  stroke-dasharray: 4 2;
  animation: pulse-pending-border 1.8s infinite ease-in-out;
  cursor: pointer;
}
.seat-circle.status-pending:hover {
  fill: #E59A3C;
  stroke: #fff;
  filter: drop-shadow(0 0 8px #E59A3C);
}

@keyframes pulse-pending-border {
  0% { stroke-opacity: 0.6; }
  50% { stroke-opacity: 1; }
  100% { stroke-opacity: 0.6; }
}

/* Seated Currently */
.seat-circle.status-seated {
  fill: #1C334D;
  stroke: #4A90E2;
  stroke-width: 2.5px;
  cursor: pointer;
}
.seat-circle.status-seated:hover {
  fill: #4A90E2;
  stroke: #fff;
  filter: drop-shadow(0 0 8px #4A90E2);
}

/* Blocked / Staff Hold */
.seat-circle.status-blocked {
  fill: #2C1B3D;
  stroke: #A55EEA;
  stroke-width: 2.5px;
  stroke-dasharray: 2 2;
  cursor: pointer;
}
.seat-circle.status-blocked:hover {
  fill: #A55EEA;
  stroke: #fff;
  filter: drop-shadow(0 0 8px #A55EEA);
}
/* Ineligible due to gender / party criteria */
.seat-circle.status-ineligible {
  fill: #24201C;
  stroke: #4D453E;
  opacity: 0.45;
  cursor: not-allowed;
}

.seat-label {
  fill: #fff;
  font-size: 9px;
  font-weight: 800;
  text-anchor: middle;
  dominant-baseline: central;
  pointer-events: none;
}

/* Floor Plan Live Info Drawer */
.floorplan-drawer {
  position: absolute;
  bottom: 16px;
  right: 16px;
  background: rgba(34, 30, 26, 0.94);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius-sm);
  padding: 14px 18px;
  box-shadow: var(--shadow-float);
  z-index: 10;
  max-width: 340px;
}

/* Interactive Notification Highlighting on Floor Plan */
@keyframes notif-target-pulse {
  0% {
    stroke: #FAB400;
    stroke-width: 4px;
    filter: drop-shadow(0 0 6px rgba(250, 180, 0, 0.85));
  }
  50% {
    stroke: #FFFFFF;
    stroke-width: 6px;
    filter: drop-shadow(0 0 16px #FAB400) drop-shadow(0 0 26px rgba(250, 180, 0, 0.95));
  }
  100% {
    stroke: #FAB400;
    stroke-width: 4px;
    filter: drop-shadow(0 0 6px rgba(250, 180, 0, 0.85));
  }
}

.seat-node.is-notif-target .seat-circle,
.seat-circle.seat-circle-highlighted {
  animation: notif-target-pulse 1.3s infinite ease-in-out !important;
  stroke: #FAB400 !important;
  stroke-width: 4.5px !important;
}

.seating-unit-group.is-notif-target .seating-unit-body {
  stroke: #FAB400 !important;
  stroke-width: 3.5px !important;
  filter: drop-shadow(0 0 16px rgba(250, 180, 0, 0.65)) !important;
  transition: stroke 0.3s ease, stroke-width 0.3s ease;
}

.active-notif-card {
  border-color: var(--accent-primary, #FAB400) !important;
  box-shadow: 0 0 16px rgba(250, 180, 0, 0.35) !important;
  background: rgba(250, 180, 0, 0.06) !important;
}
