/* ==========================================================================
   Mix It Up - Group Generator Style Sheet
   Inspired by Meri Meri Vintage Circus Partyware Aesthetic
   ========================================================================== */

:root {
  /* Authentic Circus & Partyware Palette from Photo */
  --party-bg: #85C5D2;
  --circus-red: #D92B2F;
  --circus-cream: #FAF8F2;
  --circus-gold: #C59B3C;
  --circus-gold-dark: #A67C24;
  --circus-gold-light: #F6C843;
  --circus-sage: #8DAEA1;
  --circus-pink: #E5A2AF;
  --circus-blue: #8AA5B8;
  --circus-darkgreen: #1C4E46;
  --circus-mint: #97D0C7;
  --circus-mint-dark: #5CA79B;
  --circus-mint-text: #0E352F;

  --text-main: #263238;
  --text-muted: #546E7A;
  --text-light: #90A4AE;
  --card-bg: #FAF8F2;
  --card-border: #C59B3C;
  --shadow-sm: 0 4px 14px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 10px 28px rgba(0, 0, 0, 0.12);
  --shadow-lg: 0 18px 40px rgba(0, 0, 0, 0.16);
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --radius-full: 9999px;
  --font-heading: 'Fredoka', cursive, sans-serif;
  --font-body: 'Nunito', sans-serif;
}

/* Reset & Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-body);
  background-color: var(--party-bg);
  background-image: radial-gradient(circle at 50% 30%, rgba(255, 255, 255, 0.18) 0%, rgba(0, 0, 0, 0.05) 100%);
  color: var(--text-main);
  min-height: 100vh;
  line-height: 1.5;
  overflow-x: hidden;
  position: relative;
}

/* ==========================================================================
   Circus Flat-lay Partyware Decorations (Photo Aesthetic)
   ========================================================================== */
.circus-photo-decorations {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.photo-plate {
  position: absolute;
  filter: drop-shadow(0 6px 16px rgba(0, 0, 0, 0.15));
  transition: transform 0.3s ease;
}

.plate-svg {
  width: 100%;
  height: 100%;
  display: block;
}

/* Position plates in corners bleeding off-screen like the photo */
.plate-top-left {
  top: 15px;
  left: -85px;
  width: 290px;
  height: 290px;
  transform: rotate(-12deg);
}

.plate-top-right {
  top: 15px;
  right: -85px;
  width: 290px;
  height: 290px;
  transform: rotate(18deg);
}

.plate-bottom-left {
  bottom: -95px;
  left: -95px;
  width: 300px;
  height: 300px;
  transform: rotate(24deg);
}

.plate-bottom-right {
  bottom: -95px;
  right: -95px;
  width: 300px;
  height: 300px;
  transform: rotate(-18deg);
}

/* Mint swirl lollipop disc (Bottom left in photo) */
.photo-swirl-disc {
  position: absolute;
  bottom: 25px;
  left: 175px;
  width: 125px;
  height: 125px;
  transform: rotate(25deg);
  filter: drop-shadow(0 5px 12px rgba(0, 0, 0, 0.12));
}

.swirl-svg {
  width: 100%;
  height: 100%;
}

/* Popcorn bowls along the sides */
.photo-popcorn-bowl {
  position: absolute;
  filter: drop-shadow(0 5px 12px rgba(0, 0, 0, 0.14));
}

.bowl-left {
  top: 48%;
  left: -35px;
  width: 110px;
  height: 110px;
  transform: translateY(-50%) rotate(14deg);
}

.bowl-right {
  top: 50%;
  right: -35px;
  width: 110px;
  height: 110px;
  transform: translateY(-50%) rotate(-16deg);
}

.bowl-svg {
  width: 100%;
  height: 100%;
}

@media (max-width: 900px) {
  .photo-plate {
    opacity: 0.6;
    transform: scale(0.75);
  }
  .photo-swirl-disc,
  .photo-popcorn-bowl {
    display: none;
  }
}

/* ==========================================================================
   App Layout Container
   ========================================================================== */
/* Header: Full-width top bar across the top (Bjælke hele vejen over) */
.main-header {
  width: 100%;
  background: var(--circus-cream);
  border-bottom: 2.5px solid var(--circus-gold);
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.08);
  position: relative;
  z-index: 30;
  overflow: hidden;
}

.header-awning {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 7px;
  background: repeating-linear-gradient(
    90deg,
    var(--circus-red) 0,
    var(--circus-red) 18px,
    var(--circus-cream) 18px,
    var(--circus-cream) 36px
  );
  border-bottom: 1.5px solid var(--circus-gold);
}

.header-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0.85rem 1.75rem 0.85rem;
  display: flex;
  align-items: center;
  justify-content: flex-start;
}

.logo-area {
  display: inline-flex;
  align-items: center;
  gap: 1rem;
  cursor: pointer;
  user-select: none;
  transition: transform 0.2s ease;
  background: transparent;
}

.logo-area:hover {
  transform: scale(1.02);
}

.logo-area:hover .logo-wheel-svg {
  transform: rotate(20deg) scale(1.05);
}

.logo-wheel-svg {
  width: 52px;
  height: 52px;
  display: block;
  flex-shrink: 0;
  filter: drop-shadow(0 3px 6px rgba(0, 0, 0, 0.14));
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.logo-text {
  display: flex;
  align-items: center;
}

.app-title {
  font-family: var(--font-heading);
  font-size: 1.85rem;
  font-weight: 700;
  color: var(--circus-red);
  letter-spacing: -0.5px;
  line-height: 1.1;
  display: inline-flex;
  align-items: baseline;
  gap: 0.45rem;
  flex-wrap: wrap;
}

.app-subtitle {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--circus-gold-dark);
  letter-spacing: 0.5px;
}

@media (max-width: 600px) {
  .header-inner {
    padding: 0.65rem 1rem;
  }
  .logo-wheel-svg {
    width: 42px;
    height: 42px;
  }
  .app-title {
    font-size: 1.4rem;
  }
  .app-subtitle {
    font-size: 0.95rem;
  }
}

/* ==========================================================================
   App Layout Container
   ========================================================================== */
.app-container {
  position: relative;
  z-index: 1;
  max-width: 960px;
  margin: 0 auto;
  padding: 2rem 1.25rem 1.25rem;
  min-height: calc(100vh - 72px);
  display: flex;
  flex-direction: column;
}

/* Views Management */
.view {
  display: none;
  animation: fadeIn 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.view.active {
  display: block;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ==========================================================================
   VIEW 1: Mode Selection (Photo-Inspired Circus Theme)
   ========================================================================== */
.welcome-hero {
  text-align: center;
  max-width: 650px;
  margin: 1.5rem auto 3rem;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hero-title {
  font-family: var(--font-heading);
  font-size: 2.2rem;
  font-weight: 700;
  color: #1A3038;
  margin-bottom: 0.5rem;
  letter-spacing: -0.5px;
}

.hero-description {
  color: #37535E;
  font-size: 1.15rem;
  line-height: 1.5;
}

.mode-selection-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  max-width: 860px;
  margin: 0 auto;
}

@media (max-width: 720px) {
  .mode-selection-grid {
    grid-template-columns: 1fr;
  }
}

.mode-card {
  position: relative;
  background: var(--circus-cream);
  border: 2.5px solid var(--circus-gold);
  border-radius: var(--radius-lg);
  padding: 2.5rem 2rem 2rem;
  text-align: left;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: all 0.28s cubic-bezier(0.2, 0.8, 0.2, 1);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.mode-card:hover {
  transform: translateY(-6px);
  border-color: var(--circus-red);
  box-shadow: var(--shadow-md);
}

/* Card Roof Canopies */
.card-tent-roof {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 22px;
  border-bottom: 2px solid var(--circus-gold);
}

.roof-red {
  background: repeating-linear-gradient(
    90deg,
    var(--circus-red) 0,
    var(--circus-red) 16px,
    var(--circus-cream) 16px,
    var(--circus-cream) 32px
  );
}

.roof-pastel {
  background: repeating-linear-gradient(
    90deg,
    var(--circus-sage) 0,
    var(--circus-sage) 16px,
    var(--circus-pink) 16px,
    var(--circus-pink) 32px
  );
  border-bottom-color: #6C8E82;
}

/* Scalloped bottom edge of canopy */
.scallop-trim {
  position: absolute;
  bottom: -6px;
  left: 0;
  right: 0;
  height: 6px;
  background: radial-gradient(circle at 6px -1px, transparent 6px, var(--circus-cream) 7px);
  background-size: 12px 6px;
}

.mode-title {
  font-family: var(--font-heading);
  font-size: 1.7rem;
  font-weight: 700;
  color: #1A3038;
  margin-bottom: 0.75rem;
}

.mode-desc {
  color: #4A636E;
  font-size: 1.05rem;
  line-height: 1.6;
  flex-grow: 1;
  margin-bottom: 1.75rem;
}

.mode-action {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--circus-red);
  padding-top: 1.1rem;
  border-top: 1.5px dashed #D6CEBE;
}

.circus-card-advanced .mode-action {
  color: #1C4E46;
}

.arrow-icon {
  font-size: 1.3rem;
  transition: transform 0.2s ease;
}

.mode-card:hover .arrow-icon {
  transform: translateX(6px);
}

/* ==========================================================================
   Shared Setup Navigation & Layout
   ========================================================================== */
.view-nav-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.text-btn {
  background: var(--circus-cream);
  border: 1.5px solid var(--circus-gold);
  color: #37535E;
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.5rem 1rem;
  border-radius: var(--radius-full);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
  transition: all 0.2s ease;
}

.text-btn:hover {
  background: #FFFFFF;
  border-color: var(--circus-red);
  color: var(--circus-red);
  transform: translateY(-1px);
}

.badge-mode {
  font-family: var(--font-heading);
  font-weight: 700;
  background: var(--circus-cream);
  color: var(--circus-red);
  border: 1.5px solid var(--circus-gold);
  padding: 0.4rem 1.25rem;
  border-radius: var(--radius-full);
  font-size: 0.95rem;
  letter-spacing: 0.5px;
}

.badge-mode-adv {
  color: #1C4E46;
  border-color: #8DAEA1;
}

.setup-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.75rem;
}

@media (max-width: 820px) {
  .setup-layout {
    grid-template-columns: 1fr;
  }
}

.setup-card {
  background: var(--circus-cream);
  border: 2px solid var(--circus-gold);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.75rem;
  gap: 0.5rem;
}

.card-header h3 {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 700;
  color: #1A3038;
}

.counter-pill {
  font-size: 0.85rem;
  font-weight: 800;
  background: #ECE7DA;
  color: #554A39;
  padding: 0.25rem 0.8rem;
  border-radius: var(--radius-full);
  white-space: nowrap;
}

.counter-pill.has-items {
  background: #E1EFEA;
  color: #1C4E46;
}

.input-hint {
  font-size: 0.92rem;
  color: #4A636E;
  margin-bottom: 0.75rem;
}

textarea#namesInput,
textarea#advNamesInput {
  width: 100%;
  border: 2px solid #D6CEBE;
  border-radius: var(--radius-md);
  padding: 1rem;
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.5;
  resize: vertical;
  min-height: 180px;
  outline: none;
  background: #FFFFFF;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

textarea#namesInput:focus,
textarea#advNamesInput:focus {
  border-color: var(--circus-darkgreen);
  box-shadow: 0 0 0 3px rgba(28, 78, 70, 0.18);
}

.input-actions {
  display: flex;
  gap: 0.5rem;
  margin-top: 0.85rem;
  flex-wrap: wrap;
}

.chip-btn {
  background: #FFFFFF;
  border: 1.5px solid var(--circus-gold);
  color: #554A39;
  padding: 0.45rem 1rem;
  border-radius: var(--radius-full);
  font-size: 0.88rem;
  font-weight: 700;
  font-family: var(--font-body);
  cursor: pointer;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.chip-btn:hover {
  background: #FFFDF5;
  border-color: var(--circus-red);
  color: var(--circus-red);
  transform: translateY(-1px);
}

.chip-btn-danger {
  background: #FFF0F0;
  border-color: #EFA8A8;
  color: #C62828;
}

.chip-btn-danger:hover {
  background: #FFDEDE;
  border-color: #D92B2F;
}

.chip-btn-outline {
  background: #FFFFFF;
  border: 2px solid #B0BEC5;
  color: #37474F;
}

.chip-btn-outline:hover {
  border-color: #263238;
}

/* Split Type Selector */
.split-type-selector {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  background: #EFE8D6;
  padding: 0.35rem;
  border-radius: var(--radius-md);
  margin-bottom: 1.25rem;
}

.radio-tab {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.65rem 0.5rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-weight: 700;
  font-size: 0.95rem;
  color: #554A39;
  transition: all 0.2s ease;
}

.radio-tab input {
  display: none;
}

.radio-tab.active {
  background: #FFFFFF;
  color: var(--circus-red);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
}

.control-box {
  display: none;
  background: #F4EFE3;
  border: 2px dashed #D6CEBE;
  border-radius: var(--radius-md);
  padding: 1.25rem;
  margin-bottom: 1.5rem;
}

.control-box.active {
  display: block;
}

.control-label {
  display: block;
  font-weight: 700;
  color: #1A3038;
  margin-bottom: 0.85rem;
  font-size: 1.05rem;
}

.stepper-wrapper {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  max-width: 200px;
  margin-bottom: 0.85rem;
}

.step-btn {
  width: 44px;
  height: 44px;
  background: #FFFFFF;
  border: 2px solid var(--circus-gold);
  border-radius: var(--radius-sm);
  font-size: 1.4rem;
  font-weight: 700;
  color: #1A3038;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
  user-select: none;
}

.step-btn:hover {
  background: #FFFDF5;
  border-color: var(--circus-red);
  color: var(--circus-red);
}

.stepper-wrapper input[type="number"] {
  width: 70px;
  height: 44px;
  border: 2px solid #D6CEBE;
  border-radius: var(--radius-sm);
  text-align: center;
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--circus-darkgreen);
  outline: none;
  background: #FFFFFF;
}

.calculation-summary {
  font-size: 0.95rem;
  color: #4A636E;
  background: #FFFFFF;
  border-radius: var(--radius-sm);
  padding: 0.65rem 0.85rem;
  border-left: 4px solid var(--circus-gold);
}

.action-footer {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.btn-generate {
  background: linear-gradient(180deg, #E53935 0%, #C62828 100%);
  color: #FFFFFF;
  border: 2px solid var(--circus-gold);
  border-radius: var(--radius-md);
  padding: 1rem 1.75rem;
  font-family: var(--font-heading);
  font-size: 1.45rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 18px rgba(198, 40, 40, 0.35);
  transition: all 0.2s cubic-bezier(0.2, 0.8, 0.2, 1);
  letter-spacing: 0.5px;
}

.btn-generate:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 10px 24px rgba(198, 40, 40, 0.45);
}

.error-msg {
  color: var(--circus-red);
  font-size: 0.95rem;
  font-weight: 700;
  min-height: 1.4rem;
  text-align: center;
}

/* ==========================================================================
   VIEW 3: Advanced Group Generator Setup
   ========================================================================== */
.advanced-setup-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.75rem;
}

@media (max-width: 900px) {
  .advanced-setup-grid {
    grid-template-columns: 1fr;
  }
}

.adv-step-card {
  min-height: 380px;
}

/* Table Selection Grid */
.table-types-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.65rem;
  margin-bottom: 1rem;
}

@media (max-width: 600px) {
  .table-types-grid {
    grid-template-columns: 1fr;
  }
}

.table-type-row {
  background: #FFFFFF;
  border: 1.5px solid #D6CEBE;
  border-radius: var(--radius-sm);
  padding: 0.65rem 0.75rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  transition: all 0.2s ease;
}

.table-type-row:hover {
  border-color: var(--circus-gold);
}

.table-type-row.active-type {
  border-color: var(--circus-gold);
  background: #FFFDF5;
}

.tt-info {
  display: flex;
  align-items: center;
}

.tt-details {
  display: flex;
  flex-direction: column;
}

.tt-details strong {
  font-size: 0.9rem;
  color: #1A3038;
  line-height: 1.2;
}

.tt-details span {
  font-size: 0.78rem;
  color: #78909C;
}

.stepper-mini {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.mini-btn {
  width: 28px;
  height: 28px;
  background: #FFFFFF;
  border: 1.5px solid #D6CEBE;
  border-radius: 6px;
  font-size: 1.1rem;
  font-weight: 700;
  color: #1A3038;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
}

.mini-btn:hover {
  background: #FAF8F2;
  border-color: var(--circus-gold);
  color: var(--circus-red);
}

.table-count {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 700;
  min-width: 22px;
  text-align: center;
  color: var(--circus-darkgreen);
}

.table-type-horseshoe {
  grid-column: 1 / -1;
  background: #FFFDF5;
  border-color: var(--circus-gold);
}

.table-auto-actions {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.85rem;
  flex-wrap: wrap;
}

.capacity-notice-box {
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  background: #ECE7DA;
  color: #554A39;
  font-weight: 600;
  border-left: 4px solid var(--circus-gold);
}

.capacity-notice-box.matched {
  background: #E1EFEA;
  color: #1C4E46;
  border-left-color: var(--circus-sage);
}

.capacity-notice-box.mismatch {
  background: #FFF0F0;
  color: var(--circus-red);
  border-left-color: var(--circus-red);
}

/* Step 3: Pinned table assignments */
.adv-tables-assign-container {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  max-height: 280px;
  overflow-y: auto;
  padding-right: 0.25rem;
}

.empty-state-hint {
  text-align: center;
  padding: 2.5rem 1rem;
  color: var(--text-light);
  font-style: italic;
  font-size: 0.95rem;
}

.table-assign-card {
  background: #FFFFFF;
  border: 1.5px solid #D6CEBE;
  border-radius: var(--radius-sm);
  padding: 0.75rem 1rem;
}

.tac-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.5rem;
}

.tac-title {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  color: #1A3038;
}

.tac-badge {
  font-size: 0.75rem;
  font-weight: 800;
  background: #ECE7DA;
  padding: 0.15rem 0.5rem;
  border-radius: var(--radius-full);
  color: #554A39;
}

.tac-content {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.tac-select-row {
  display: flex;
  gap: 0.5rem;
}

.tac-select-row select {
  flex-grow: 1;
  padding: 0.35rem 0.65rem;
  border: 1.5px solid #D6CEBE;
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: 0.9rem;
  outline: none;
  background: #FFFFFF;
}

.tac-pinned-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.pinned-tag {
  background: #E1EFEA;
  border: 1px solid #8DAEA1;
  color: #1C4E46;
  font-weight: 700;
  font-size: 0.85rem;
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-full);
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.pinned-tag button {
  background: transparent;
  border: none;
  color: #1C4E46;
  cursor: pointer;
  font-weight: 800;
  font-size: 0.9rem;
  line-height: 1;
}

/* Step 4: Deltagere der IKKE må sidde sammen (Dynamiske felter) */
.separation-fields-container {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.sep-field-card {
  background: #FFFDF9;
  border: 1.5px solid #E6DCCD;
  border-radius: var(--radius-sm);
  padding: 0.75rem 0.9rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  transition: border-color 0.15s ease;
}

.sep-field-card:focus-within {
  border-color: var(--circus-gold-dark);
}

.sep-field-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.sep-field-title {
  font-size: 0.82rem;
  font-weight: 800;
  color: #554A39;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.btn-sep-field-remove {
  background: transparent;
  border: none;
  color: var(--circus-darkgreen);
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  padding: 0.2rem 0.45rem;
  border-radius: 4px;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  transition: background-color 0.15s, color 0.15s;
}

.btn-sep-field-remove:hover {
  background: rgba(28, 78, 70, 0.1);
  color: #0E352F;
}

.sep-field-body {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
}

.sep-person-wrap {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  flex: 1 1 180px;
  min-width: 150px;
}

.sep-person-select {
  flex: 1;
  padding: 0.5rem 0.65rem;
  border: 1.5px solid #D6CEBE;
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: 0.9rem;
  background: #FFFFFF;
  color: #2E281F;
  outline: none;
  transition: border-color 0.15s ease;
}

.sep-person-select:focus {
  border-color: var(--circus-gold-dark);
}

.sep-person-remove-btn {
  background: #F5EFEB;
  border: 1px solid #D6CEBE;
  color: #554A39;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 700;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
  flex-shrink: 0;
}

.sep-person-remove-btn:hover {
  background: rgba(28, 78, 70, 0.1);
  color: var(--circus-darkgreen);
  border-color: var(--circus-darkgreen);
}

.sep-divider {
  font-weight: 700;
  color: var(--circus-darkgreen);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 0 0.15rem;
  user-select: none;
  flex-shrink: 0;
}

.btn-sep-add-person {
  background: #F4EFE6;
  border: 1px dashed #C2B49D;
  color: #554A39;
  font-size: 0.8rem;
  font-weight: 700;
  padding: 0.4rem 0.7rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.btn-sep-add-person:hover {
  background: #EAE3D6;
  border-color: #887B68;
}

.empty-separation-hint {
  font-size: 0.85rem;
  color: var(--text-light);
  font-style: italic;
  padding: 0.5rem 0;
}

.separation-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Advanced Footer Bar with READY button */
.adv-footer-bar {
  margin-top: 1.75rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
}

.btn-ready-action {
  background: linear-gradient(180deg, #1C4E46 0%, #133933 100%);
  color: #FFFFFF;
  border: 2px solid var(--circus-gold);
  border-radius: var(--radius-md);
  padding: 1.15rem 2.5rem;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  box-shadow: 0 8px 22px rgba(28, 78, 70, 0.35);
  transition: all 0.25s cubic-bezier(0.2, 0.8, 0.2, 1);
  text-align: center;
  max-width: 500px;
  width: 100%;
}

.btn-ready-action:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 12px 28px rgba(28, 78, 70, 0.45);
}

.btn-ready-action .ready-title {
  font-family: var(--font-heading);
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: -0.2px;
}

.btn-ready-action .ready-sub {
  font-size: 0.85rem;
  opacity: 0.9;
  font-weight: 600;
}

/* ==========================================================================
   VIEW 4: Advanced Presentation Ready Screen
   ========================================================================== */
.ready-hero-card {
  background: var(--circus-cream);
  border: 2.5px solid var(--circus-gold);
  border-radius: var(--radius-lg);
  padding: 3.5rem 2rem;
  text-align: center;
  max-width: 700px;
  margin: 1.5rem auto;
  box-shadow: var(--shadow-md);
  display: flex;
  flex-direction: column;
  align-items: center;
}

.ready-main-title {
  font-family: var(--font-heading);
  font-size: 2.3rem;
  color: #1A3038;
  margin-bottom: 0.75rem;
}

.ready-main-desc {
  color: #4A636E;
  font-size: 1.15rem;
  max-width: 520px;
  margin-bottom: 2rem;
  line-height: 1.5;
}

.ready-main-actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  width: 100%;
}

.btn-generate-large {
  min-width: 260px;
  padding: 1.15rem 2.2rem;
  font-size: 1.6rem;
}

/* ==========================================================================
   VIEW 5: Animated Bee Reveal Stage
   ========================================================================== */
.reveal-nav {
  margin-bottom: 1rem;
}

.reveal-status-pill {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 700;
  background: var(--circus-cream);
  color: var(--circus-red);
  border: 2px solid var(--circus-gold);
  padding: 0.4rem 1.25rem;
  border-radius: var(--radius-full);
}

.primary-pill-btn {
  background: var(--circus-cream);
  color: var(--circus-red);
  border: 2px solid var(--circus-gold);
  padding: 0.5rem 1.25rem;
  border-radius: var(--radius-full);
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  transition: all 0.2s ease;
}

.primary-pill-btn:hover {
  background: #FFFFFF;
  border-color: var(--circus-red);
  transform: translateY(-1px);
}

/* Bee & Nature Stage */
.bee-stage {
  position: relative;
  width: 100%;
  min-height: 520px;
  height: clamp(520px, 62vh, 660px);
  background: linear-gradient(180deg, #D4EDF2 0%, #FAF8F2 60%, #E6EFEA 100%);
  border: 3px solid var(--circus-gold);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  overflow: hidden;
  margin-bottom: 1.5rem;
  transition: background 0.5s ease, min-height 0.3s ease;
}

/* Theme backdrops */
.bee-stage.theme-bee {
  background: linear-gradient(180deg, #D4EDF2 0%, #FAF8F2 60%, #E6EFEA 100%);
}
.bee-stage.theme-ant {
  background: linear-gradient(180deg, #FFE8D6 0%, #F5ECE3 45%, #D7CCC8 100%);
}
.bee-stage.theme-elephant {
  background: linear-gradient(180deg, #E0F2F1 0%, #E8F5E9 50%, #C8E6C9 100%);
}
.bee-stage.theme-dolphin {
  background: linear-gradient(180deg, #B2EBF2 0%, #E0F7FA 45%, #80DEEA 100%);
}
.bee-stage.theme-bird {
  background: linear-gradient(180deg, #E1F5FE 0%, #FFF9C4 50%, #DCEDC8 100%);
}

#confettiCanvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 10;
}

/* Visibility toggling for 5 sceneries */
.stage-scenery {
  display: none;
}
.bee-stage.theme-bee .scenery-bee {
  display: block;
}
.bee-stage.theme-ant .scenery-ant {
  display: block;
}
.bee-stage.theme-elephant .scenery-elephant {
  display: block;
}
.bee-stage.theme-dolphin .scenery-dolphin {
  display: block;
}
.bee-stage.theme-bird .scenery-bird {
  display: block;
}

/* THEME 1 SCENERY: Tree Branch & Hive */
.tree-branch {
  position: absolute;
  top: 0;
  left: 0;
  width: 320px;
  height: 60px;
  z-index: 2;
  pointer-events: none;
}

.branch-svg {
  width: 100%;
  height: 100%;
  filter: drop-shadow(0 3px 6px rgba(0, 0, 0, 0.15));
}

.beehive-container {
  position: absolute;
  top: 28px;
  left: 55px;
  width: 110px;
  z-index: 3;
  transform-origin: top center;
  animation: hiveSway 5s ease-in-out infinite;
}

.hive-rope {
  width: 4px;
  height: 18px;
  background: #8D6E63;
  margin: 0 auto;
  border-radius: 2px;
}

.beehive-svg {
  width: 100%;
  height: auto;
  filter: drop-shadow(0 6px 12px rgba(62, 39, 35, 0.25));
}

@keyframes hiveSway {
  0%, 100% { transform: rotate(0deg); }
  25% { transform: rotate(1.5deg); }
  75% { transform: rotate(-1.5deg); }
}

/* THEME 2 SCENERY: Tall Anthill, Dense Grass & Ant Caravan */
.scenery-ant {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.anthill-container {
  position: absolute;
  bottom: 0;
  left: clamp(15px, 3vw, 40px);
  width: clamp(210px, 28vw, 290px);
  z-index: 3;
  pointer-events: none;
}

.anthill-svg {
  width: 100%;
  height: auto;
  filter: drop-shadow(0 8px 18px rgba(62, 39, 35, 0.35));
}

.ant-dense-grass {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 62px;
  z-index: 1;
  pointer-events: none;
}

.dense-grass-svg {
  width: 100%;
  height: 100%;
}

.ant-caravan {
  position: absolute;
  bottom: 8px;
  right: clamp(10px, 3vw, 45px);
  width: clamp(300px, 48vw, 440px);
  height: 65px;
  z-index: 3;
  pointer-events: none;
}

.caravan-svg {
  width: 100%;
  height: 100%;
  overflow: visible;
  filter: drop-shadow(0 3px 6px rgba(0, 0, 0, 0.16));
}

/* Caravan March Animation (Cute staggered walking bobs) */
.caravan-ant-1 {
  animation: antCaravanBob1 0.55s ease-in-out infinite alternate;
  transform-origin: bottom center;
}

.caravan-ant-2 {
  animation: antCaravanBob2 0.55s ease-in-out infinite alternate 0.14s;
  transform-origin: bottom center;
}

.caravan-ant-3 {
  animation: antCaravanBob3 0.55s ease-in-out infinite alternate 0.28s;
  transform-origin: bottom center;
}

.caravan-ant-4 {
  animation: antCaravanBob4 0.55s ease-in-out infinite alternate 0.42s;
  transform-origin: bottom center;
}

@keyframes antCaravanBob1 {
  0% { transform: translateY(0px) rotate(0deg); }
  100% { transform: translateY(-3.5px) rotate(-1.5deg); }
}

@keyframes antCaravanBob2 {
  0% { transform: translateY(0px) rotate(0deg); }
  100% { transform: translateY(-3.5px) rotate(1.5deg); }
}

@keyframes antCaravanBob3 {
  0% { transform: translateY(0px) rotate(0deg); }
  100% { transform: translateY(-3px) rotate(-1deg); }
}

@keyframes antCaravanBob4 {
  0% { transform: translateY(0px) rotate(0deg); }
  100% { transform: translateY(-3px) rotate(1deg); }
}

/* THEME 3 SCENERY: Detailed Palm Trees on Left and Right */
.scenery-elephant {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 2;
}

.palm-tree {
  position: absolute;
  bottom: 0;
  height: 100%;
  width: clamp(170px, 24vw, 240px);
  pointer-events: none;
}

.palm-tree-left {
  left: 0;
}

.palm-tree-right {
  right: 0;
}

.palm-tree-svg {
  width: 100%;
  height: 100%;
  overflow: visible;
  filter: drop-shadow(0 4px 10px rgba(27, 94, 32, 0.22));
}

.palm-crown-left {
  transform-origin: 78px 180px;
  animation: palmCrownSwayLeft 5s ease-in-out infinite alternate;
}

.palm-crown-right {
  transform-origin: 162px 180px;
  animation: palmCrownSwayRight 5s ease-in-out infinite alternate 0.6s;
}

@keyframes palmCrownSwayLeft {
  0% { transform: rotate(0deg); }
  50% { transform: rotate(2deg) scale(1.01); }
  100% { transform: rotate(-1.5deg); }
}

@keyframes palmCrownSwayRight {
  0% { transform: rotate(0deg); }
  50% { transform: rotate(-2deg) scale(1.01); }
  100% { transform: rotate(1.5deg); }
}

/* THEME 4 SCENERY: Ocean Waves */
.ocean-waves-container {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 110px;
  z-index: 2;
  pointer-events: none;
}

.waves-svg {
  width: 100%;
  height: 100%;
  animation: oceanWavesFloat 4s ease-in-out infinite alternate;
}

@keyframes oceanWavesFloat {
  0% { transform: translateY(0px) scaleY(1); }
  100% { transform: translateY(5px) scaleY(1.04); }
}

/* THEME 5 SCENERY: Blooming Branch */
.bird-branch-container {
  position: absolute;
  top: 0;
  right: 0;
  width: 380px;
  z-index: 2;
  pointer-events: none;
  transform-origin: top right;
  animation: birdBranchSway 5s ease-in-out infinite;
}

.bird-branch-svg {
  width: 100%;
  height: auto;
  filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.15));
}

@keyframes birdBranchSway {
  0%, 100% { transform: rotate(0deg); }
  50% { transform: rotate(-1.8deg); }
}

/* THEME 5 SCENERY: Sunflowers growing from bottom-left */
.sunflower-cluster-container {
  position: absolute;
  bottom: 0;
  left: clamp(10px, 3.5vw, 42px);
  width: clamp(160px, 22vw, 240px);
  height: clamp(230px, 42vh, 320px);
  pointer-events: none;
  z-index: 2;
  transform-origin: bottom center;
  animation: sunflowerSway 6.5s ease-in-out infinite alternate;
}

.sunflower-svg {
  width: 100%;
  height: 100%;
  overflow: visible;
  filter: drop-shadow(0 4px 12px rgba(46, 125, 50, 0.22));
}

@keyframes sunflowerSway {
  0% { transform: rotate(0deg); }
  50% { transform: rotate(1.8deg) scaleY(1.01); }
  100% { transform: rotate(-1.5deg); }
}

.sunflower-head {
  pointer-events: none;
}


/* The Animated Actor (Character + Banner) */
.bee-actor {
  position: absolute;
  width: 380px;
  max-width: calc(100% - 32px);
  left: 50%;
  top: 44%;
  transform: translate(-50%, -50%);
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: center;
  pointer-events: none;
  transition: transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.4s ease, width 0.35s ease, max-width 0.35s ease;
}

/* Dynamic width expansion so all names fit comfortably without scrolling */
.bee-actor.size-compact {
  width: 380px;
}

.bee-actor.size-medium {
  width: 560px;
  max-width: calc(100% - 32px);
}

.bee-actor.size-large {
  width: 720px;
  max-width: calc(100% - 32px);
}

.bee-actor.size-xlarge {
  width: 860px;
  max-width: calc(100% - 32px);
}

.bee-actor.size-xlarge .member-chip {
  font-size: 1.02rem;
  padding: 0.3rem 0.8rem;
}

/* Synchronized floating carrier: bee and banner float together with zero gap */
.actor-flying-unit {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  animation: actorBob 2.6s ease-in-out infinite;
}

@keyframes actorBob {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-6px);
  }
}

/* Visibility toggling for 5 characters */
.character-wrapper {
  display: none;
  position: relative;
  overflow: visible;
  filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.22));
}

.bee-stage.theme-bee .char-bee {
  display: block;
}
.bee-stage.theme-ant .char-ant {
  display: block;
}
.bee-stage.theme-elephant .char-elephant {
  display: block;
}
.bee-stage.theme-dolphin .char-dolphin {
  display: block;
}
.bee-stage.theme-bird .char-bird {
  display: block;
}

/* Character 1: Bee */
.char-bee {
  width: 120px;
  height: 95px;
  position: relative;
}

.bee-svg {
  width: 100%;
  height: 100%;
  overflow: visible;
}

.wing-front {
  transform-origin: 62px 17px;
  animation: wingFlap 0.08s ease-in-out infinite alternate;
}

.wing-back {
  transform-origin: 75px 20px;
  animation: wingFlap 0.08s ease-in-out infinite alternate 0.04s;
}

@keyframes wingFlap {
  0% { transform: rotate(15deg) scaleY(1); }
  100% { transform: rotate(55deg) scaleY(0.4); }
}

/* Character 2: Ant */
.char-ant {
  width: 110px;
  height: 95px;
  position: relative;
}

.ant-svg {
  width: 100%;
  height: 100%;
  overflow: visible;
}

/* Character 3: Elephant */
.char-elephant {
  width: 130px;
  height: 95px;
  position: relative;
}

.elephant-svg {
  width: 100%;
  height: 100%;
  overflow: visible;
}

/* Character 4: Dolphin */
.char-dolphin {
  width: 135px;
  height: 95px;
  position: relative;
}

.dolphin-svg {
  width: 100%;
  height: 100%;
  overflow: visible;
}

/* Character 5: Bird */
.char-bird {
  width: 115px;
  height: 95px;
  position: relative;
}

.bird-svg {
  width: 100%;
  height: 100%;
  overflow: visible;
}

.bird-wing-back {
  transform-origin: 45px 20px;
  animation: birdWingBackFlap 0.22s ease-in-out infinite alternate;
}

.bird-wing-front {
  transform-origin: 50px 40px;
  animation: birdWingFrontFlap 0.22s ease-in-out infinite alternate 0.05s;
}

@keyframes birdWingBackFlap {
  0% { transform: rotate(20deg) scaleY(1); }
  100% { transform: rotate(45deg) scaleY(0.6); }
}

@keyframes birdWingFrontFlap {
  0% { transform: rotate(-15deg); }
  100% { transform: rotate(10deg); }
}

/* Entrance Animations per Theme */

/* 1. Bee flies out from beehive */
.theme-bee .bee-actor.fly-in {
  animation: beeFlyOutFromHive 1.1s cubic-bezier(0.2, 0.8, 0.25, 1) forwards;
}

@keyframes beeFlyOutFromHive {
  0% {
    transform: translate(-300px, -110px) scale(0.2) rotate(-25deg);
    opacity: 0;
  }
  30% { opacity: 1; }
  65% { transform: translate(-50%, -42%) scale(1.1) rotate(5deg); }
  85% { transform: translate(-50%, -52%) scale(0.96) rotate(-2deg); }
  100% { transform: translate(-50%, -50%) scale(1) rotate(0deg); opacity: 1; }
}

/* 2. Ant marches out from anthill */
.theme-ant .bee-actor.fly-in {
  animation: antMarchOutFromHill 1.15s cubic-bezier(0.2, 0.85, 0.3, 1) forwards;
}

@keyframes antMarchOutFromHill {
  0% {
    transform: translate(-280px, 150px) scale(0.22) rotate(-16deg);
    opacity: 0;
  }
  35% { opacity: 1; }
  62% { transform: translate(-50%, -40%) scale(1.1) rotate(4deg); }
  82% { transform: translate(-50%, -53%) scale(0.97) rotate(-2deg); }
  100% { transform: translate(-50%, -50%) scale(1) rotate(0deg); opacity: 1; }
}

/* 3. Elephant emerges proud from jungle */
.theme-elephant .bee-actor.fly-in {
  animation: elephantEmergeFromJungle 1.2s cubic-bezier(0.18, 0.9, 0.3, 1) forwards;
}

@keyframes elephantEmergeFromJungle {
  0% {
    transform: translate(-50%, -150px) scale(0.28) rotate(10deg);
    opacity: 0;
    filter: blur(4px);
  }
  40% { opacity: 1; filter: blur(0); }
  65% { transform: translate(-50%, -40%) scale(1.12) rotate(-4deg); }
  85% { transform: translate(-50%, -53%) scale(0.97) rotate(1deg); }
  100% { transform: translate(-50%, -50%) scale(1) rotate(0deg); opacity: 1; }
}

/* 4. Dolphin leaps up from ocean waves */
.theme-dolphin .bee-actor.fly-in {
  animation: dolphinLeapFromWaves 1.15s cubic-bezier(0.25, 0.9, 0.35, 1) forwards;
}

@keyframes dolphinLeapFromWaves {
  0% {
    transform: translate(-50%, 170px) scale(0.28) rotate(-35deg);
    opacity: 0;
  }
  30% { opacity: 1; }
  58% { transform: translate(-50%, -66%) scale(1.12) rotate(10deg); }
  80% { transform: translate(-50%, -46%) scale(0.96) rotate(-3deg); }
  100% { transform: translate(-50%, -50%) scale(1) rotate(0deg); opacity: 1; }
}

/* 5. Bird swoops down onto branch */
.theme-bird .bee-actor.fly-in {
  animation: birdSwoopOntoBranch 1.1s cubic-bezier(0.22, 0.85, 0.36, 1) forwards;
}

@keyframes birdSwoopOntoBranch {
  0% {
    transform: translate(260px, -150px) scale(0.24) rotate(26deg);
    opacity: 0;
  }
  35% { opacity: 1; }
  64% { transform: translate(-50%, -42%) scale(1.09) rotate(-5deg); }
  84% { transform: translate(-50%, -52%) scale(0.97) rotate(2deg); }
  100% { transform: translate(-50%, -50%) scale(1) rotate(0deg); opacity: 1; }
}

/* Hanging Banner */
.bee-banner {
  width: 100%;
  margin-top: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  transform-origin: top center;
  animation: bannerSway 3.2s ease-in-out infinite;
}

@keyframes bannerSway {
  0%, 100% { transform: rotate(0deg); }
  33% { transform: rotate(1deg); }
  66% { transform: rotate(-1deg); }
}

.banner-strings {
  width: 28px;
  height: 12px;
  display: flex;
  justify-content: space-between;
  margin: -1px auto 0 auto;
  position: relative;
  z-index: 2;
}

.string {
  width: 3.5px;
  height: 100%;
  background: #8D6E63;
  border-radius: 1px;
  position: relative;
}

.string::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 50%;
  transform: translateX(-50%);
  width: 7px;
  height: 7px;
  background: var(--circus-gold);
  border: 1.5px solid #8D6E63;
  border-radius: 50%;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
}

.banner-board {
  width: 100%;
  background: var(--circus-cream);
  border: 3.5px solid var(--circus-gold);
  border-radius: 18px;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.18), inset 0 2px 4px rgba(255, 255, 255, 0.9);
  padding: 1.1rem 1.25rem;
  position: relative;
  overflow: hidden;
}

.banner-board::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 6px;
  background: repeating-linear-gradient(
    90deg,
    var(--circus-red) 0,
    var(--circus-red) 12px,
    var(--circus-cream) 12px,
    var(--circus-cream) 24px
  );
}

.banner-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
}

.banner-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  justify-content: center;
}

.banner-badge {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--circus-red);
  letter-spacing: -0.3px;
}

.banner-type-badge {
  font-size: 0.85rem;
  font-weight: 700;
  background: #FFFFFF;
  color: var(--circus-gold-dark);
  padding: 0.2rem 0.65rem;
  border-radius: var(--radius-full);
  border: 1px solid var(--circus-gold);
}

.banner-members-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  max-height: none;
  overflow: visible;
  padding: 0.35rem 0.25rem;
}

.member-chip {
  background: #FFFFFF;
  border: 2px solid var(--circus-gold);
  color: #1A3038;
  font-weight: 700;
  font-size: 1.1rem;
  padding: 0.35rem 0.9rem;
  border-radius: var(--radius-full);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
  animation: popIn 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275) both;
}

@keyframes popIn {
  0% { transform: scale(0.6); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

.reveal-controls-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
}

.step-nav-btn {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 700;
  padding: 0.85rem 1.6rem;
  border-radius: var(--radius-full);
  cursor: pointer;
  border: none;
  transition: all 0.2s ease;
  min-width: 160px;
  text-align: center;
}

.primary-nav-btn {
  background: linear-gradient(180deg, #E53935 0%, #C62828 100%);
  color: #FFFFFF;
  border: 2px solid var(--circus-gold);
  box-shadow: 0 6px 18px rgba(198, 40, 40, 0.3);
}

.primary-nav-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(198, 40, 40, 0.4);
}

.secondary-nav-btn {
  background: var(--circus-cream);
  border: 2px solid var(--circus-gold);
  color: #37535E;
}

.secondary-nav-btn:hover:not(:disabled) {
  background: #FFFFFF;
  color: #1A3038;
}

.secondary-nav-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.icon-nav-btn {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--circus-cream);
  border: 2px solid var(--circus-gold);
  color: var(--circus-gold-dark);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.icon-nav-btn:hover {
  transform: rotate(45deg);
  border-color: var(--circus-red);
  color: var(--circus-red);
}

/* ==========================================================================
   VIEW 6: Overview & Visual Floor Plan
   ========================================================================== */
.view-mode-tabs {
  display: flex;
  background: rgba(0, 0, 0, 0.08);
  padding: 0.3rem;
  border-radius: var(--radius-full);
  gap: 0.35rem;
}

.view-tab {
  background: transparent;
  border: none;
  padding: 0.45rem 1rem;
  border-radius: var(--radius-full);
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 700;
  color: #37535E;
  cursor: pointer;
  transition: all 0.2s ease;
}

.view-tab.active {
  background: #FFFFFF;
  color: var(--circus-red);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.overview-top-actions {
  display: flex;
  gap: 0.75rem;
}

.overview-tab-pane {
  display: none;
}

.overview-tab-pane.active {
  display: block;
}

.printable-wrapper {
  background: var(--circus-cream);
  border: 2.5px solid var(--circus-gold);
  border-radius: var(--radius-lg);
  padding: 2rem;
  box-shadow: var(--shadow-sm);
  margin-bottom: 1.5rem;
}

.overview-header,
.floorplan-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 1.5rem;
  border-bottom: 2px dashed #D6CEBE;
  margin-bottom: 1.75rem;
  gap: 1rem;
  flex-wrap: wrap;
}

.overview-title-group {
  display: flex;
  align-items: center;
}

.overview-title {
  font-family: var(--font-heading);
  font-size: 1.85rem;
  font-weight: 700;
  color: #1A3038;
}

.overview-meta {
  color: #4A636E;
  font-size: 0.95rem;
}

.overview-stats-badge {
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 700;
  background: #FFFFFF;
  color: var(--circus-red);
  padding: 0.5rem 1.15rem;
  border-radius: var(--radius-full);
  border: 1.5px solid var(--circus-gold);
}

.groups-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1.25rem;
}

.group-summary-card {
  background: #FFFFFF;
  border: 2px solid #D6CEBE;
  border-radius: var(--radius-md);
  padding: 1.25rem;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  page-break-inside: avoid;
  break-inside: avoid;
}

.group-summary-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.08);
}

.group-summary-card.theme-0 { border-top: 5px solid var(--circus-red); }
.group-summary-card.theme-1 { border-top: 5px solid var(--circus-gold); }
.group-summary-card.theme-2 { border-top: 5px solid var(--circus-sage); }
.group-summary-card.theme-3 { border-top: 5px solid var(--circus-pink); }
.group-summary-card.theme-4 { border-top: 5px solid var(--circus-blue); }
.group-summary-card.theme-5 { border-top: 5px solid var(--circus-darkgreen); }

.group-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.85rem;
}

.group-card-title {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  color: #1A3038;
}

.group-count-tag {
  font-size: 0.8rem;
  font-weight: 800;
  background: #ECE7DA;
  color: #554A39;
  padding: 0.2rem 0.55rem;
  border-radius: var(--radius-full);
}

.group-card-members {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

/* Wide card layout for U-form and single table setups */
.groups-grid.has-single-card {
  grid-template-columns: 1fr;
}

.group-summary-card.is-wide-card,
.group-summary-card.is-horseshoe-card {
  grid-column: 1 / -1;
}

.group-summary-card.is-wide-card .group-card-members,
.group-summary-card.is-horseshoe-card .group-card-members {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 0.45rem 0.85rem;
}

.group-card-member {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.05rem;
  font-weight: 600;
  color: #1A3038;
  padding: 0.35rem 0.65rem;
  background: var(--circus-cream);
  border-radius: var(--radius-sm);
  border: 1px solid #E5DFD0;
}

.member-bullet {
  color: var(--circus-gold);
  font-size: 1.1rem;
  line-height: 1;
}

/* ==========================================================================
   Visual Classroom Floor Plan / Bordopstilling
   ========================================================================== */
.room-front-banner {
  background: var(--circus-mint);
  color: var(--circus-mint-text);
  border: 2px solid var(--circus-mint-dark);
  border-radius: var(--radius-md);
  padding: 0.85rem 1.5rem;
  text-align: center;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 2rem;
  box-shadow: 0 4px 14px rgba(151, 208, 199, 0.35);
}

.classroom-layout-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 2rem;
  padding: 1rem 0;
}

.classroom-layout-grid.layout-row {
  grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
}

/* Visual Desk Unit */
.desk-unit {
  background: #FFFFFF;
  border: 2px solid var(--circus-gold);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  display: flex;
  flex-direction: column;
  align-items: center;
  page-break-inside: avoid;
  break-inside: avoid;
  transition: transform 0.2s ease;
  overflow-x: auto;
}

.desk-unit:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.desk-surface {
  background: #FAF8F2;
  border: 2px solid var(--circus-gold);
  border-radius: 12px;
  padding: 0.85rem 1.25rem;
  text-align: center;
  width: 100%;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.05);
  margin-bottom: 1rem;
}

.desk-surface-title {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--circus-darkgreen);
}

.desk-surface-type {
  font-size: 0.8rem;
  font-weight: 800;
  color: var(--circus-gold-dark);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Seats surrounding the table */
.desk-seats-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
  width: 100%;
}

.seat-chair-pill {
  background: #FAF8F2;
  border: 1.5px solid #D6CEBE;
  border-radius: var(--radius-full);
  padding: 0.35rem 0.85rem;
  font-size: 0.95rem;
  font-weight: 700;
  color: #1A3038;
  display: inline-flex;
  align-items: center;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.04);
}

.seat-chair-pill.seat-occupied {
  background: #FFFFFF;
  border-color: var(--circus-gold);
  color: #1A3038;
}

.seat-chair-pill.seat-empty {
  border-style: dashed;
  color: #90A4AE;
  background: #FAF8F2;
  font-size: 0.85rem;
  font-weight: 600;
}

.desk-unit-horseshoe {
  grid-column: 1 / -1;
  background: #FFFDF8;
  border-color: var(--circus-gold);
}

.desk-unit-horseshoe .desk-surface {
  border: 2.5px solid var(--circus-gold);
  border-radius: 20px 20px 8px 8px;
}

.print-only-footer {
  display: none;
}

.overview-bottom-bar {
  display: flex;
  justify-content: center;
}

.secondary-btn {
  background: var(--circus-cream);
  border: 2px solid var(--circus-gold);
  color: #37535E;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius-full);
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.secondary-btn:hover {
  background: #FFFFFF;
  border-color: var(--circus-red);
  color: var(--circus-red);
}

/* ==========================================================================
   Site Footer Attribution (Centered at the Bottom)
   ========================================================================== */
.site-footer {
  margin-top: auto;
  padding: 1.75rem 0 0 0;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  position: relative;
  z-index: 2;
}

.site-footer-text {
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 700;
  color: #17423B;
  text-align: center;
  line-height: 1.45;
  letter-spacing: 0.15px;
  background: rgba(250, 248, 242, 0.7);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  padding: 0.45rem 1.25rem;
  border-radius: var(--radius-full);
  border: 1.5px solid rgba(197, 155, 60, 0.45);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.06);
  transition: all 0.25s ease;
}

.site-footer-text:hover {
  background: rgba(250, 248, 242, 0.95);
  border-color: var(--circus-gold);
  color: #0E2E28;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.1);
  transform: translateY(-1px);
}

@media (max-width: 640px) {
  .site-footer {
    padding-top: 1.25rem;
  }
  .site-footer-text {
    font-size: 0.8rem;
    border-radius: var(--radius-md);
    padding: 0.5rem 0.85rem;
  }
}

/* ==========================================================================
   Floor Plan Mode Switcher & Interactive Canvas Sheet (Design selv)
   ========================================================================== */
.floorplan-mode-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}

.fp-mode-toggles {
  display: inline-flex;
  background: #ECE6D8;
  padding: 4px;
  border-radius: var(--radius-full);
  gap: 4px;
}

.btn-fp-mode {
  background: transparent;
  border: none;
  padding: 0.45rem 1rem;
  border-radius: var(--radius-full);
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 700;
  color: #554A39;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  transition: all 0.2s ease;
}

.btn-fp-mode.active {
  background: #FFFFFF;
  color: var(--circus-red);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.fp-grid-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.fp-shape-toggle-group {
  display: inline-flex;
  background: #ECE6D8;
  padding: 4px;
  border-radius: var(--radius-full);
  gap: 4px;
}

.btn-grid-shape {
  background: transparent;
  border: none;
  padding: 0.45rem 1rem;
  border-radius: var(--radius-full);
  font-family: var(--font-body);
  font-size: 0.88rem;
  font-weight: 700;
  color: #554A39;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.btn-grid-shape:hover {
  color: var(--circus-darkgreen);
}

.btn-grid-shape.active {
  background: #FFFFFF;
  color: var(--circus-darkgreen);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.fp-canvas-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

/* Floor Plan Tray (Unplaced tables) */
.fp-tray-panel {
  background: #FAF8F2;
  border: 2px dashed #D6CEBE;
  border-radius: var(--radius-md);
  padding: 1rem 1.25rem;
  margin-bottom: 1.25rem;
}

.fp-tray-header {
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
  flex-wrap: wrap;
}

.fp-tray-title {
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 700;
  color: #1A3038;
}

.fp-tray-hint {
  font-size: 0.85rem;
  color: #665C4D;
  font-style: italic;
}

.fp-tray-items {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}

.fp-tray-item {
  background: #FFFFFF;
  border: 1.5px solid var(--circus-gold);
  border-radius: var(--radius-sm);
  padding: 0.5rem 0.85rem;
  cursor: grab;
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.04);
  transition: all 0.15s ease;
  user-select: none;
}

.fp-tray-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
  border-color: var(--circus-red);
}

.fp-tray-item:active {
  cursor: grabbing;
}

.fp-tray-item-title {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--circus-darkgreen);
}

.fp-tray-item-count {
  font-size: 0.8rem;
  font-weight: 700;
  background: #ECE7DA;
  color: #554A39;
  padding: 0.15rem 0.45rem;
  border-radius: var(--radius-full);
}

.btn-tray-place-mini {
  background: var(--circus-mint);
  color: var(--circus-mint-text);
  border: 1.5px solid var(--circus-mint-dark);
  border-radius: 4px;
  padding: 0.2rem 0.55rem;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 1px 3px rgba(14, 53, 47, 0.1);
  transition: all 0.15s ease;
}

.btn-tray-place-mini:hover {
  background: #7EC5BA;
  color: var(--circus-mint-text);
  border-color: #4B9287;
}

/* Floor Plan Interactive Canvas Sheet */
.fp-canvas-wrapper {
  width: 100%;
  position: relative;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.fp-canvas-sheet {
  position: relative;
  width: 100%;
  min-height: 780px;
  height: auto;
  background-color: #FFFFFF;
  border: 2px solid #D6CEBE;
  border-radius: var(--radius-md);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
  overflow: hidden;
  user-select: none;
  touch-action: pan-y;
  transition: min-height 0.2s ease;
}

@media (max-width: 680px) {
  .fp-canvas-sheet {
    min-width: 680px;
  }
}

.fp-canvas-sheet.show-grid {
  background-image: radial-gradient(#D6CEBE 1.25px, transparent 1.25px);
  background-size: 24px 24px;
}

.fp-canvas-inner {
  width: 100%;
  height: 100%;
  position: relative;
}

/* Draggable Board on Canvas */
.fp-board-item {
  position: absolute;
  z-index: 20;
  cursor: move;
  touch-action: none;
  transform-origin: center center;
  transition: box-shadow 0.15s ease;
}

.fp-board-item.is-dragging {
  z-index: 100 !important;
  opacity: 0.92;
}

.fp-board-inner {
  background: var(--circus-mint);
  color: var(--circus-mint-text);
  border: 2px solid var(--circus-mint-dark);
  border-radius: var(--radius-md);
  padding: 0.55rem 1.15rem;
  display: inline-flex;
  align-items: center;
  gap: 0.85rem;
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 700;
  box-shadow: 0 4px 14px rgba(151, 208, 199, 0.35);
  white-space: nowrap;
}

.fp-board-inner .fp-drag-handle {
  color: var(--circus-mint-text) !important;
  font-weight: 700;
}

.btn-fp-board-rot {
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid var(--circus-mint-dark);
  color: var(--circus-mint-text);
  border-radius: 4px;
  padding: 0.2rem 0.45rem;
  font-size: 0.75rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  line-height: 1;
  transition: all 0.15s ease;
}

.btn-fp-board-rot:hover {
  background: #FFFFFF;
  color: var(--circus-mint-text);
  border-color: #4B9287;
}

/* Placed Tables on Canvas */
.fp-placed-table {
  position: absolute;
  z-index: 10;
  cursor: move;
  touch-action: none;
  transform-origin: center center;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  user-select: none;
  transition: box-shadow 0.15s ease;
}

.fp-placed-table.is-selected {
  z-index: 25;
}

.fp-placed-table.is-dragging {
  z-index: 100 !important;
  opacity: 0.95;
}

.fp-placed-table.is-dragging .desk-surface-slab {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25) !important;
}

.fp-placed-table.is-selected .desk-surface-slab,
.fp-placed-table.is-selected .hs-unit-desk {
  border-color: var(--circus-mint-dark);
  box-shadow: 0 0 0 2px var(--circus-mint), 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Table Toolbar on top - visible only when table is selected */
.fp-table-toolbar {
  position: absolute;
  bottom: calc(100% + 5px);
  left: 50%;
  transform: translateX(-50%);
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 0.45rem;
  background: rgba(255, 255, 255, 0.98);
  padding: 0.22rem 0.5rem;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--circus-gold);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12);
  white-space: nowrap;
  z-index: 30;
  animation: fpToolbarPop 0.12s ease-out;
}

.fp-placed-table.is-selected .fp-table-toolbar {
  display: flex;
}

@keyframes fpToolbarPop {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(4px) scale(0.96);
  }
  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0) scale(1);
  }
}

.fp-drag-handle {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-family: var(--font-heading);
  font-size: 0.92rem;
  color: var(--circus-darkgreen);
}

.fp-table-actions {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
}

.btn-fp-shape {
  background: #FAF6ED;
  border: 1px solid #D6CEBE;
  border-radius: 4px;
  padding: 0.2rem 0.45rem;
  font-size: 0.72rem;
  font-weight: 700;
  color: #554A39;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  transition: all 0.15s ease;
}

.btn-fp-shape:hover {
  background: #E9E1D2;
  color: var(--circus-darkgreen);
  border-color: var(--circus-darkgreen);
}

.btn-fp-rotate {
  background: #FAF6ED;
  border: 1px solid #D6CEBE;
  border-radius: 4px;
  padding: 0.2rem 0.4rem;
  font-size: 0.72rem;
  font-weight: 700;
  color: #554A39;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  transition: all 0.15s ease;
}

.btn-fp-rotate:hover {
  background: #E9E1D2;
  color: var(--circus-red);
  border-color: var(--circus-red);
}

.btn-fp-remove {
  background: transparent;
  border: none;
  color: #887B68;
  font-size: 1.15rem;
  line-height: 1;
  cursor: pointer;
  padding: 0 0.2rem;
  font-weight: 800;
  transition: color 0.15s ease;
}

.btn-fp-remove:hover {
  color: var(--circus-red);
}

/* Realistic Desk Assembly */
.desk-real-assembly {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  width: 100%;
}

/* The Central Desk Surface / Table Slab */
.desk-surface-slab {
  background: linear-gradient(180deg, #FBF8F2 0%, #F1E8DC 100%);
  border: 2px solid #C59B3C;
  border-radius: 8px;
  padding: 0.45rem 1rem;
  text-align: center;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.9);
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.desk-slab-island {
  min-width: 180px;
  max-width: 280px;
  min-height: 48px;
}

.desk-slab-row {
  min-width: 250px;
  max-width: 580px;
  min-height: 38px;
}

.slab-title {
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--circus-darkgreen);
  line-height: 1.2;
}

.slab-type {
  font-size: 0.72rem;
  font-weight: 800;
  color: var(--circus-gold-dark);
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

/* Seats row around the desk */
.desk-seats-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
}

.seats-top {
  margin-bottom: 2px;
}

.seats-bottom {
  margin-top: 2px;
}

.seats-linear {
  margin-bottom: 3px;
}

/* Individual Chairs / Seats */
.real-chair-seat {
  background: #FFFFFF;
  border: 1.5px solid var(--circus-mint-dark);
  border-radius: 6px;
  padding: 4px 8px;
  font-size: 0.82rem;
  font-weight: 700;
  color: #1A3038;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 62px;
  max-width: 110px;
  text-align: center;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.06);
  position: relative;
  transition: transform 0.15s ease;
}

.real-chair-seat .chair-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 95px;
}

.real-chair-seat.chair-empty {
  background: #FAF8F2;
  border-style: dashed;
  border-color: #B4A894;
  color: #8C806E;
  font-style: italic;
  font-weight: 600;
  font-size: 0.78rem;
}

/* Horseshoe Assembly: U-form sammensat af enkeltmandsborde */
.desk-real-assembly.shape-horseshoe {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 100%;
  padding: 0.6rem 0.5rem;
}

.hs-front-opening {
  width: 100%;
  max-width: 320px;
  text-align: center;
  margin-bottom: 0.65rem;
  padding-bottom: 0.35rem;
  border-bottom: 2px dashed rgba(28, 78, 70, 0.25);
}

.hs-board-tag {
  font-family: var(--font-heading);
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--circus-darkgreen);
  text-transform: uppercase;
  letter-spacing: 0.6px;
  background: rgba(28, 78, 70, 0.08);
  border: 1.5px solid rgba(28, 78, 70, 0.25);
  padding: 0.22rem 1.1rem;
  border-radius: 999px;
  display: inline-block;
}

.hs-body-row {
  display: flex;
  align-items: stretch;
  justify-content: space-between;
  width: 100%;
  gap: 12px;
}

.hs-col-wing {
  display: flex;
  flex-direction: column;
  gap: 7px;
  flex-shrink: 0;
}

.hs-center-courtyard {
  flex: 1;
  min-width: 140px;
  min-height: 80px;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  outline: none !important;
  pointer-events: none;
  margin: 0 4px;
}

.hs-bottom-row {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 6px;
  width: 100%;
  margin-top: 10px;
  flex-wrap: wrap;
}

/* Individual single desk units (1 plads pr. enkeltmandsbord) */
.hs-single-unit {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.hs-unit-bottom {
  flex-direction: column;
  gap: 4px;
}

.hs-unit-desk {
  background: #FAF8F2;
  border: 1.5px solid var(--circus-gold);
  border-radius: 5px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.hs-unit-left .hs-unit-desk,
.hs-unit-right .hs-unit-desk {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
}

.hs-unit-bottom .hs-unit-desk {
  width: 62px;
  height: 20px;
  flex-shrink: 0;
}

/* ==========================================================================
   PRINT STYLES
   ========================================================================== */
@page {
  margin: 0;
  size: auto;
}

@media print {
  html, body {
    background: #FFFFFF !important;
    color: #000000 !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  .circus-photo-decorations,
  .main-header,
  .no-print,
  .view-nav-bar,
  .overview-bottom-bar,
  #homeView,
  #setupView,
  #advancedSetupView,
  #advancedReadyView,
  #revealView {
    display: none !important;
  }

  .app-container {
    max-width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
  }

  #overviewView {
    display: block !important;
  }

  .overview-tab-pane {
    display: none !important;
  }

  .overview-tab-pane.active {
    display: block !important;
  }

  .printable-wrapper {
    border: none !important;
    box-shadow: none !important;
    padding: 0.8cm 1.2cm 1cm 1.2cm !important;
    box-sizing: border-box !important;
    background: #FFFFFF !important;
  }

  #floorPlanPrintable {
    page-break-inside: avoid !important;
    break-inside: avoid !important;
  }

  .overview-header,
  .floorplan-header {
    border-bottom: 2px solid #000000 !important;
    padding-bottom: 0.8rem !important;
    margin-bottom: 1.25rem !important;
  }

  .overview-title {
    font-size: 1.8rem !important;
    color: #000000 !important;
  }

  .room-front-banner {
    background: #EEEEEE !important;
    color: #000000 !important;
    border: 2px solid #000000 !important;
    box-shadow: none !important;
  }

  .groups-grid,
  .classroom-layout-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 1.25rem !important;
  }

  .groups-grid.has-single-card,
  .classroom-layout-grid.has-single-card {
    grid-template-columns: 1fr !important;
  }

  .group-summary-card,
  .desk-unit {
    border: 1.5px solid #444444 !important;
    background: #FFFFFF !important;
    box-shadow: none !important;
    break-inside: avoid !important;
    page-break-inside: avoid !important;
  }

  .group-summary-card.is-wide-card,
  .group-summary-card.is-horseshoe-card,
  .desk-unit-horseshoe {
    grid-column: 1 / -1 !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  .group-summary-card.is-wide-card .group-card-members,
  .group-summary-card.is-horseshoe-card .group-card-members {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 0.35rem 0.65rem !important;
  }

  .group-summary-card.is-wide-card .group-card-member,
  .group-summary-card.is-horseshoe-card .group-card-member {
    font-size: 0.95rem !important;
    padding: 0.28rem 0.55rem !important;
    background: #FAFAFA !important;
    border: 1px solid #777777 !important;
    break-inside: avoid !important;
    page-break-inside: avoid !important;
  }

  .desk-surface {
    background: #F0F0F0 !important;
    border: 1.5px solid #000000 !important;
    box-shadow: none !important;
  }

  .group-card-member,
  .seat-chair-pill {
    border: 1px solid #777777 !important;
    background: #FFFFFF !important;
    color: #000000 !important;
  }

  .floorplan-mode-bar,
  .fp-grid-actions,
  .fp-tray-panel,
  .btn-fp-board-rot,
  .fp-table-actions,
  .fp-table-toolbar,
  .desk-unit-toolbar {
    display: none !important;
  }

  .fp-canvas-sheet {
    border: 1.5px solid #000000 !important;
    background: #FFFFFF !important;
    background-image: none !important;
    box-shadow: none !important;
    width: var(--fp-print-width, 100%) !important;
    max-width: none !important;
    min-height: var(--fp-print-height, 780px) !important;
    height: var(--fp-print-height, 780px) !important;
    overflow: visible !important;
    page-break-inside: avoid !important;
    break-inside: avoid !important;
    box-sizing: border-box !important;
    transform: scale(var(--fp-print-scale, 1));
    transform-origin: top center;
    margin: 0 auto !important;
    margin-bottom: calc((var(--fp-print-scale, 1) - 1) * var(--fp-print-height, 780px)) !important;
  }

  .fp-canvas-inner {
    width: 100%;
    height: 100%;
    position: relative;
    transform: translate(var(--fp-print-shift-x, 0px), var(--fp-print-shift-y, 0px));
  }

  .fp-board-inner {
    background: #EEEEEE !important;
    color: #000000 !important;
    border: 2px solid #000000 !important;
    box-shadow: none !important;
  }

  .fp-placed-table {
    box-shadow: none !important;
    background: transparent !important;
    page-break-inside: avoid !important;
  }

  .desk-surface-slab {
    background: #F4F4F4 !important;
    border: 1.5px solid #000000 !important;
    box-shadow: none !important;
  }

  .slab-title {
    color: #000000 !important;
  }

  .slab-type {
    color: #444444 !important;
  }

  .real-chair-seat {
    border: 1.5px solid #000000 !important;
    background: #FFFFFF !important;
    color: #000000 !important;
    box-shadow: none !important;
  }


  .real-chair-seat.chair-empty {
    border-color: #666666 !important;
    color: #666666 !important;
    background: #FAFAFA !important;
  }

  .print-only-footer {
    display: block !important;
    position: fixed;
    bottom: 0.8cm;
    left: 0;
    right: 0;
    text-align: center;
    font-size: 0.82rem;
    color: #555555;
    background: transparent !important;
    margin: 0 !important;
    padding: 0 !important;
    z-index: 9999;
  }

  .print-only-footer p {
    margin: 0 !important;
    padding: 0 !important;
    font-size: 0.82rem !important;
    color: #555555 !important;
  }
}
