/* Sticky page-level action bar sits just below the navbar */
#pageBar {
  position: sticky;
  top: 0;
  z-index: 1020;
  background: #1a1a2e;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
/* Tighten card padding on smaller screens */
@media (max-width: 575px) {
  .card-body {
    padding: 1rem;
  }
}
/* Subtle section-number badge */
.section-badge{
  /* --bs-primary-rgb: 13, 110, 253; */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.6rem;
  height: 1.6rem;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  font-size: 0.75rem;
  font-weight: lighter;
  margin-right: 0.5rem;
  flex-shrink: 0;
}

.card-title, .form-label{
  /* color: rgb(248, 249, 250); */
  font-weight: lighter;
}

/* ── Form control overrides ──────────────────────────────────────────────────
   Bootstrap's bg-dark class sets --bs-body-color to near-black which makes
   placeholder text invisible. Override once here for the whole page.
   Using the project's existing --secondary-text token (#b4b4b4) for placeholders
   and --primary-text (#fff) for entered values so contrast is clear.           */
#propertyCreateForm .form-control,
#propertyCreateForm .form-select {
  color: var(--primary-text, #fff);
}

#propertyCreateForm .form-control::placeholder,
#propertyCreateForm .form-select::placeholder {
  color: var(--secondary-text, #b4b4b4);
  opacity: 1;   /* Bootstrap sets opacity on ::placeholder — reset it */
}

/* ── Image staging grid ──────────────────────────────────────────────────────*/
.image-staging-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 0.75rem;
}

.image-card {
  position: relative;
  aspect-ratio: 4 / 3;
  border-radius: 8px;
  overflow: hidden;
  cursor: grab;
  border: 2px solid transparent;
  background: rgba(255,255,255,0.05);
}

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

.image-slot-chip {
  position: absolute;
  top: 0.35rem;
  left: 0.35rem;
  background: rgba(0,0,0,0.65);
  color: #fff;
  font-size: 0.65rem;
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  pointer-events: none;
  white-space: nowrap;
  max-width: calc(100% - 0.7rem);
  overflow: hidden;
  text-overflow: ellipsis;
}

.image-card-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.55);
  opacity: 0;
  transition: opacity 0.18s;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 0.4rem;
}

.image-card:hover .image-card-overlay {
  opacity: 1;
}

.image-card.dragging {
  opacity: 0.4;
  cursor: grabbing;
}

.image-card.drag-over {
  border-color: rgba(255,255,255,0.7);
  outline: 2px dashed rgba(255,255,255,0.5);
}

.image-empty-state {
  grid-column: 1 / -1;
  padding: 1.5rem 0;
  text-align: center;
}
/* ── Wizard Layout ────────────────────────────────────────────────────────────
   Desktop: sidebar nav on the left, step panels on the right.
   Mobile:  nav becomes a compact scrollable progress bar across the top.          */

.wizard-layout {
  display: flex;
  gap: 1.5rem;
  align-items: flex-start;
}

/* ── Sidebar nav ─────────────────────────────────────────────────────────────*/
.wizard-nav {
  flex: 0 0 200px;
  position: sticky;
  top: 64px; /* clears #pageBar */
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.wizard-nav-pill {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
  border: none;
  background: transparent;
  color: rgba(255, 255, 255, 0.45);
  font-size: 0.82rem;
  text-align: left;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
  white-space: nowrap;
  width: 100%;
}

.wizard-nav-pill:hover {
  background: rgba(255, 255, 255, 0.07);
  color: rgba(255, 255, 255, 0.75);
}

.wizard-nav-pill.active {
  background: rgba(13, 110, 253, 0.2);
  color: #fff;
  font-weight: 500;
}

.wizard-nav-pill.completed {
  color: rgba(255, 255, 255, 0.65);
}

.wizard-nav-pill .wn-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.4rem;
  height: 1.4rem;
  border-radius: 50%;
  font-size: 0.7rem;
  font-weight: 600;
  flex-shrink: 0;
  background: rgba(255, 255, 255, 0.1);
  color: inherit;
}

.wizard-nav-pill.active .wn-num {
  background: #0d6efd;
  color: #fff;
}

.wizard-nav-pill.completed .wn-num {
  background: rgba(25, 135, 84, 0.5);
  color: #75b798;
}

/* ── Step panels ────────────────────────────────────────────────────────────*/
.wizard-panels {
  flex: 1 1 0;
  min-width: 0;
}

.wizard-step.d-none {
  display: none !important;
}

/* ── Mobile: hide sidebar, show compact numbered progress bar ───────────────*/
@media (max-width: 767px) {
  .wizard-layout {
    flex-direction: column;
    gap: 0.75rem;
  }

  .wizard-nav {
    flex: none;
    position: static;
    flex-direction: row;
    overflow-x: auto;
    gap: 0.25rem;
    padding-bottom: 0.25rem;
    width: 100%;
  }

  .wizard-nav-pill {
    flex: 0 0 auto;
    padding: 0.35rem 0.6rem;
    font-size: 0.75rem;
  }

  /* On mobile, hide the text label — show only the number chip */
  .wizard-nav-pill .wn-label {
    display: none;
  }
}
