/* ========================================================
   WellRiskKeeper - PWA 모바일 현장 조사 전용 스타일시트
   ======================================================== */

.pwa-container {
  max-width: 520px;
  margin: 0 auto;
  padding: 12px 14px 80px 14px;
}

/* 5-Step Navigation Tabs */
.pwa-step-tabs {
  display: flex;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  padding: 3px;
  border-radius: 6px;
  margin-bottom: 12px;
  gap: 3px;
  overflow-x: auto;
}
.pwa-tab-item {
  flex: 1;
  min-width: 60px;
  background: transparent;
  border: 1px solid transparent;
  color: #64748b;
  padding: 7px 4px;
  border-radius: 4px;
  font-size: 11.5px;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  white-space: nowrap;
  transition: all 0.15s ease;
}
.pwa-tab-item:hover {
  color: #0f172a;
  background: rgba(255, 255, 255, 0.5);
}
.pwa-tab-item.active {
  background: #ffffff;
  color: #0f172a;
  font-weight: 600;
  border-color: #cbd5e1;
}
.tab-num-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 15px;
  height: 15px;
  border-radius: var(--radius-full);
  background: #e2e8f0;
  color: #475569;
  font-size: 9.5px;
  font-weight: 600;
}
.pwa-tab-item.active .tab-num-badge {
  background: #0f172a;
  color: #ffffff;
}

/* Section Switching */
.pwa-view-section {
  display: none;
}
.pwa-view-section.active {
  display: block;
}

/* Common Card UI */
.pwa-card {
  background: #ffffff;
  border-radius: 6px;
  border: 1px solid #e2e8f0;
  box-shadow: none;
  padding: 16px;
  margin-bottom: 12px;
}

.card-header-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--navy-100);
}
.card-main-title {
  font-size: 13px;
  font-weight: 800;
  color: var(--navy-950);
  letter-spacing: -0.02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Forms */
.form-group {
  margin-bottom: 12px;
  position: relative;
}
.form-label {
  display: block;
  font-size: 11.5px;
  font-weight: 700;
  color: var(--navy-800);
  margin-bottom: 5px;
}
.form-label .req {
  color: #b45309;
  margin-left: 2px;
}
.form-input {
  width: 100%;
  padding: 9px 12px;
  border: 1px solid var(--navy-300);
  border-radius: var(--radius-sm);
  font-size: 12.5px;
  color: var(--navy-900);
  background: #ffffff;
  box-sizing: border-box;
  transition: border-color 0.15s ease;
}
.form-input:focus {
  outline: none;
  border-color: var(--navy-700);
  box-shadow: 0 0 0 2px rgba(15, 23, 42, 0.08);
}
.form-input[readonly] {
  background: var(--navy-50);
  color: var(--navy-700);
  cursor: default;
}

/* Autocomplete */
.autocomplete-layer {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: var(--radius-sm);
  box-shadow: none;
  z-index: 100;
  max-height: 200px;
  overflow-y: auto;
  display: none;
}
.auto-item {
  padding: 9px 12px;
  cursor: pointer;
  border-bottom: 1px solid var(--navy-100);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.auto-item:last-child {
  border-bottom: none;
}
.auto-item:hover {
  background: var(--navy-50);
}

/* Dynamic Inspector List */
.inspector-row {
  display: flex;
  gap: 6px;
  align-items: center;
  margin-bottom: 6px;
}
.btn-del-inspector {
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid var(--navy-300);
  background: var(--navy-50);
  color: var(--navy-800);
  font-weight: 700;
  border-radius: var(--radius-sm);
  cursor: pointer;
}

/* Action Buttons (5:5 Grid Ratio) */
.btn-action-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 18px;
}
.btn-primary-action {
  padding: 10px 14px;
  min-height: 42px;
  background: #1e293b;
  color: #ffffff;
  border: 1px solid #1e293b;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  text-align: center;
  box-shadow: none;
  transition: all 0.15s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}
.btn-primary-action:hover {
  background: #0f172a;
  border-color: #0f172a;
}
.btn-secondary-action {
  padding: 10px 14px;
  min-height: 42px;
  background: #ffffff;
  color: #475569;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  text-align: center;
  transition: all 0.15s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}
.btn-secondary-action:hover {
  background: #f8fafc;
  color: #0f172a;
  border-color: #94a3b8;
}

/* Housing 10-Chip 2-Column Wide Grid */
.housing-chip-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
  margin-top: 6px;
}
.housing-chip {
  padding: 9px 8px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--navy-200);
  background: #ffffff;
  font-size: 12px;
  font-weight: 600;
  color: var(--navy-700);
  cursor: pointer;
  text-align: center;
  user-select: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: all 0.15s ease;
}
.housing-chip:hover {
  background: var(--navy-50);
}
.housing-chip.selected {
  background: var(--navy-800);
  color: #ffffff;
  border-color: var(--navy-950);
  font-weight: 700;
}

/* ========================================================
   Step 3: 현장 관찰 기록 모바일 토글 카드 UI
   ======================================================== */
.obs-summary-meta {
  background: var(--navy-50);
  border: 1px solid var(--navy-200);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  margin-bottom: 12px;
  font-size: 11.5px;
  color: var(--navy-800);
  display: flex;
  justify-content: space-between;
}

.obs-card-item {
  background: #ffffff;
  border: 1px solid var(--navy-200);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  margin-bottom: 8px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  transition: all 0.15s ease;
}
.obs-card-item.risk-active {
  border-color: #d97706;
  background: #fefce8;
}
.obs-card-text {
  font-size: 12px;
  font-weight: 600;
  color: var(--navy-900);
  line-height: 1.45;
  flex: 1;
  word-break: keep-all;
}
.obs-toggle-group {
  display: flex;
  gap: 4px;
  flex-shrink: 0;
}
.obs-btn-switch {
  padding: 6px 10px;
  font-size: 11px;
  font-weight: 700;
  border-radius: 3px;
  border: 1px solid var(--navy-300);
  background: #ffffff;
  color: var(--navy-600);
  cursor: pointer;
  transition: all 0.15s ease;
}
.obs-btn-switch.selected-clean {
  background: var(--navy-100);
  border-color: var(--navy-400);
  color: var(--navy-900);
}
.obs-btn-switch.selected-risk {
  background: #b45309;
  border-color: #92400e;
  color: #ffffff;
}

.obs-memo-textarea {
  width: 100%;
  min-height: 80px;
  padding: 8px 10px;
  border: 1px solid var(--navy-300);
  border-radius: var(--radius-sm);
  font-size: 12px;
  color: var(--navy-900);
  box-sizing: border-box;
  font-family: inherit;
  resize: vertical;
}
.obs-memo-textarea:focus {
  outline: none;
  border-color: var(--navy-700);
}

/* ========================================================
   Step 4: 10대 문항 대화형 FSM 질문 카드
   ======================================================== */
.q-card {
  background: #ffffff;
  border-radius: 6px;
  border: 1px solid #e2e8f0;
  box-shadow: none;
  margin-bottom: 12px;
  overflow: visible;
}
.q-card.step-hidden {
  display: none;
}
.q-card-header {
  padding: 11px 13px;
  border-bottom: 1px solid #f1f5f9;
  display: flex;
  align-items: center;
  gap: 8px;
}
.q-num-pill {
  font-size: 10px;
  font-weight: 600;
  background: #f1f5f9;
  color: #334155;
  padding: 2px 7px;
  border-radius: 3px;
}
.q-title {
  font-size: 13.5px;
  font-weight: 600;
  color: #0f172a;
  flex: 1;
}
.q-score-badge {
  font-size: 11px;
  font-weight: 600;
  color: #64748b;
}
.q-score-badge.risk {
  color: #b45309;
  font-weight: 700;
}

.q-card-body {
  padding: 13px;
}
.coaching-panel {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  padding: 10px;
  margin-bottom: 10px;
}
.dialogue-step {
  margin-bottom: 8px;
}
.dialogue-step:last-child {
  margin-bottom: 0;
}
.step-head-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 4px;
}
.step-tag {
  font-size: 10.5px;
  font-weight: 700;
  color: var(--navy-700);
}
.step-speech {
  font-size: 12.5px;
  line-height: 1.45;
  color: var(--navy-900);
  font-weight: 500;
}
.step-r-group {
  display: flex;
  gap: 5px;
  align-items: center;
  margin-top: 6px;
}
.step-r-label {
  font-size: 10.5px;
  color: var(--navy-500);
  font-weight: 600;
}
.step-r-btn {
  position: relative;
  padding: 5px 10px;
  font-size: 11.5px;
  font-weight: 600;
  border-radius: var(--radius-sm);
  border: 1px solid var(--navy-300);
  background: #ffffff;
  color: var(--navy-800);
  cursor: pointer;
  transition: all 0.15s ease;
}
.step-r-btn.selected-clean {
  background: var(--navy-100);
  border-color: var(--navy-400);
  font-weight: 700;
}
.step-r-btn.selected-risk {
  background: #b45309;
  border-color: #92400e;
  color: #ffffff;
  font-weight: 700;
}

/* Compact Speech Bubble Tooltip */
.step-tooltip-popup {
  position: absolute;
  bottom: calc(100% + 8px);
  right: 0;
  background: var(--navy-950);
  color: #ffffff;
  padding: 7px 10px;
  border-radius: 4px;
  font-size: 11px;
  line-height: 1.4;
  white-space: normal;
  width: max-content;
  max-width: 220px;
  box-shadow: 0 4px 14px rgba(8, 17, 30, 0.4);
  z-index: 200;
  pointer-events: none;
  animation: tooltipFadeIn 0.15s ease-out;
  text-align: left;
}
.step-tooltip-popup::after {
  content: '';
  position: absolute;
  top: 100%;
  right: 14px;
  border-width: 5px;
  border-style: solid;
  border-color: var(--navy-950) transparent transparent transparent;
}
.step-tooltip-title {
  display: block;
  font-size: 10px;
  font-weight: 800;
  color: #fde68a;
  margin-bottom: 3px;
}
.step-tooltip-body {
  display: block;
  font-size: 11px;
  color: #f1f5f9;
}

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

.action-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 10px;
}
.btn-toggle {
  padding: 9px 8px;
  font-size: 11.5px;
  font-weight: 600;
  border: 1px solid var(--navy-300);
  border-radius: var(--radius-sm);
  background: #ffffff;
  color: var(--navy-700);
  cursor: pointer;
  text-align: center;
  transition: all 0.15s ease;
}
.btn-toggle.selected-clean {
  background: var(--navy-100);
  border-color: var(--navy-400);
  color: var(--navy-900);
  font-weight: 700;
}
.btn-toggle.selected-risk {
  background: #b45309;
  border-color: #92400e;
  color: #ffffff;
  font-weight: 700;
}

.cause-box {
  background: var(--navy-20);
  border: 1px dashed var(--navy-300);
  border-radius: var(--radius-sm);
  padding: 10px;
  margin-top: 8px;
  display: none;
}
.cause-box.show {
  display: block;
}
.cause-title {
  font-size: 11px;
  font-weight: 700;
  color: var(--navy-800);
  margin-bottom: 6px;
}
.cause-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5px;
}
.cause-chip {
  background: #ffffff;
  border: 1px solid var(--navy-200);
  border-radius: var(--radius-sm);
  padding: 6px 8px;
  font-size: 11px;
  cursor: pointer;
}
.cause-chip.selected {
  background: var(--navy-800);
  color: #ffffff;
  border-color: var(--navy-950);
  font-weight: 600;
}
.cause-chip.cause-chip-other {
  grid-column: span 2;
  text-align: left;
  font-weight: 600;
  border-style: dashed;
  background: #f8fafc;
}
.cause-chip.cause-chip-other.selected {
  border-style: solid;
  background: var(--navy-800);
  color: #ffffff;
}

.q-memo-input {
  width: 100%;
  padding: 8px 10px;
  font-size: 11.5px;
  background: #ffffff;
  border: 1px solid var(--navy-300);
  border-radius: var(--radius-sm);
  box-sizing: border-box;
}
.q-memo-input:focus {
  outline: none;
  border-color: var(--navy-700);
}

.step-nav-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid var(--navy-100);
}
.btn-step-nav {
  padding: 8px 14px;
  min-height: 38px;
  font-size: 12px;
  font-weight: 500;
  border-radius: 6px;
  border: 1px solid #cbd5e1;
  background: #ffffff;
  color: #475569;
  cursor: pointer;
  transition: all 0.15s ease;
}
.btn-step-nav:hover {
  background: #f8fafc;
  color: #0f172a;
}
.btn-step-nav.btn-step-next {
  background: #1e293b;
  color: #ffffff;
  border: 1px solid #1e293b;
  font-weight: 600;
  box-shadow: none;
}
.btn-step-nav.btn-step-next:hover {
  background: #0f172a;
  border-color: #0f172a;
}

/* ========================================================
   Step 5: 개인정보 동의 & 전자서명
   ======================================================== */
.consent-box {
  background: var(--navy-50);
  border: 1px solid var(--navy-200);
  border-radius: var(--radius-sm);
  padding: 12px;
  margin-bottom: 12px;
}
.consent-title {
  font-size: 12.5px;
  font-weight: 800;
  color: var(--navy-900);
  margin-bottom: 6px;
}
.consent-text {
  font-size: 11.5px;
  color: var(--navy-700);
  line-height: 1.5;
  margin-bottom: 8px;
}
.consent-radio-wrap {
  display: flex;
  gap: 12px;
}
.consent-radio-label {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--navy-900);
  display: flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
}

.sig-row-card {
  background: #ffffff;
  border: 1px solid var(--navy-200);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}
.sig-row-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.sig-role-label {
  font-size: 10.5px;
  color: var(--navy-500);
  font-weight: 600;
}
.sig-name-val {
  font-size: 13px;
  font-weight: 800;
  color: var(--navy-950);
}
.sig-box-preview {
  min-width: 110px;
  height: 44px;
  border: 1px dashed var(--navy-400);
  border-radius: 3px;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 2px;
  transition: all 0.15s ease;
}
.sig-box-preview:hover {
  border-color: var(--navy-800);
  background: var(--navy-50);
}
.sig-placeholder-text {
  font-size: 11px;
  font-weight: 700;
  color: var(--navy-800);
}
.sig-preview-img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

/* Review Summary Card */
.review-summary-card {
  background: #ffffff;
  border-radius: 6px;
  border: 1px solid #e2e8f0;
  box-shadow: none;
  margin-top: 14px;
  overflow: hidden;
}
.review-summary-head {
  background: #f8fafc;
  color: #0f172a;
  border-bottom: 1px solid #e2e8f0;
  padding: 10px 14px;
  font-size: 13px;
  font-weight: 600;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.review-summary-body {
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.review-item-row {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 4px;
  padding: 8px 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.review-item-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 11.5px;
  line-height: 1.4;
  color: #334155;
}
.review-item-title {
  font-weight: 600;
  color: #0f172a;
  font-size: 12px;
}
.btn-edit-jump {
  background: #ffffff;
  border: 1px solid #cbd5e1;
  color: #334155;
  padding: 4px 10px;
  font-size: 11px;
  font-weight: 600;
  border-radius: 4px;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s ease;
}
.btn-edit-jump:hover {
  background: #1e293b;
  color: #ffffff;
  border-color: #1e293b;
}

/* ========================================================
   Floating Bottom Live Score Bar (오직 4단계에서만 노출)
   ======================================================== */
.pwa-score-bar-sticky {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--navy-950);
  color: #ffffff;
  padding: 10px 16px;
  display: none; /* 기본 숨김, 4단계에서만 flex로 노출 */
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid #334155;
  box-shadow: none;
  z-index: 90;
}
.pwa-sticky-score {
  font-size: 18px;
  font-weight: 800;
}
.pwa-sticky-score span {
  font-size: 11px;
  color: var(--navy-200);
  font-weight: 500;
}

/* ========================================================
   In-App Toast & Modal Notifications
   ======================================================== */
.wrk-toast-container {
  position: fixed;
  bottom: 64px;
  left: 50%;
  transform: translateX(-50%);
  width: calc(100% - 32px);
  max-width: 480px;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  gap: 8px;
  pointer-events: none;
}
.wrk-toast {
  background: var(--navy-950);
  color: #ffffff;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  box-shadow: none;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12.5px;
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.25s ease, transform 0.25s ease;
  pointer-events: auto;
  border: 1px solid #334155;
  border-left: 3px solid var(--navy-400);
}
.wrk-toast.show {
  opacity: 1;
  transform: translateY(0);
}
.wrk-toast-badge {
  font-size: 10px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 2px;
  flex-shrink: 0;
}
.wrk-toast-badge-info { background: var(--navy-700); color: #ffffff; }
.wrk-toast-badge-success { background: #166534; color: #dcfce7; }
.wrk-toast-badge-warning { background: #9a3412; color: #ffedd5; }
.wrk-toast-badge-error { background: #991b1b; color: #fee2e2; }
.wrk-toast-text {
  flex: 1;
  line-height: 1.4;
  word-break: keep-all;
}

.wrk-modal-container {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.wrk-modal-container.active {
  display: flex;
}
.wrk-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
}
.wrk-modal-card {
  position: relative;
  background: #ffffff;
  width: 100%;
  max-width: 420px;
  border-radius: 8px;
  box-shadow: none;
  border: 1px solid #cbd5e1;
  overflow: hidden;
  animation: modalPop 0.2s ease-out;
}
.wrk-modal-header {
  padding: 13px 16px;
  background: #f8fafc;
  color: #0f172a;
  border-bottom: 1px solid #e2e8f0;
}
.wrk-modal-title {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
}
.wrk-modal-body {
  padding: 16px;
}
.wrk-modal-desc {
  margin: 0 0 12px 0;
  font-size: 13px;
  color: #334155;
  line-height: 1.5;
}
.wrk-modal-details {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 10px;
}
.wrk-modal-detail-row {
  display: flex;
  justify-content: space-between;
  font-size: 11.5px;
}
.wrk-modal-detail-label {
  color: #64748b;
  font-weight: 500;
}
.wrk-modal-detail-val {
  color: #0f172a;
  font-weight: 600;
}
.wrk-modal-footer {
  padding: 12px 16px;
  background: #f8fafc;
  border-top: 1px solid #e2e8f0;
  display: flex;
  justify-content: flex-end;
}

/* Signature Modal */
.sig-modal-container {
  position: fixed;
  inset: 0;
  z-index: 3000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
}
.sig-modal-container.active {
  display: flex;
}
.sig-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.5);
}
.sig-modal-card {
  position: relative;
  background: #ffffff;
  width: 100%;
  max-width: 400px;
  border-radius: 8px;
  box-shadow: none;
  border: 1px solid #cbd5e1;
  overflow: hidden;
  animation: modalPop 0.2s ease-out;
}
.sig-modal-header {
  padding: 12px 16px;
  background: #f8fafc;
  color: #0f172a;
  border-bottom: 1px solid #e2e8f0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.sig-modal-title {
  font-size: 13.5px;
  font-weight: 600;
  margin: 0;
}
.sig-btn-close {
  background: transparent;
  border: none;
  color: #64748b;
  font-size: 20px;
  cursor: pointer;
  line-height: 1;
}
.sig-btn-close:hover {
  color: #0f172a;
}
.sig-modal-body {
  padding: 16px;
  background: #ffffff;
}
.sig-canvas-wrap {
  position: relative;
  width: 100%;
  height: 180px;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 4px;
  box-shadow: none;
  touch-action: none;
}
#sigCanvas {
  width: 100%;
  height: 100%;
  cursor: crosshair;
  display: block;
}
.sig-guide-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 12px;
  color: #94a3b8;
  pointer-events: none;
  font-weight: 500;
}
.sig-modal-footer {
  padding: 12px 16px;
  background: #f8fafc;
  border-top: 1px solid #e2e8f0;
  display: flex;
  gap: 8px;
}
.sig-btn-clear {
  flex: 1;
}
.sig-btn-save {
  flex: 2;
}

@keyframes modalPop {
  0% { transform: scale(0.96); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

/* Step Edit In-Place Modal (Step 5) */
.step-edit-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.5);
  z-index: 3000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  animation: modalPop 0.15s ease-out;
}
.step-edit-modal-card {
  position: relative;
  background: #ffffff;
  width: 100%;
  max-width: 480px;
  max-height: 85vh;
  border-radius: 8px;
  box-shadow: none;
  border: 1px solid #cbd5e1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: modalPop 0.18s ease-out;
}
.step-edit-modal-header {
  padding: 13px 18px;
  background: #f8fafc;
  color: #0f172a;
  border-bottom: 1px solid #e2e8f0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.step-edit-modal-title {
  font-size: 13.5px;
  font-weight: 600;
  margin: 0;
}
.step-edit-modal-close {
  background: transparent;
  border: none;
  color: #64748b;
  font-size: 20px;
  cursor: pointer;
  line-height: 1;
}
.step-edit-modal-close:hover {
  color: #0f172a;
}
.step-edit-modal-body {
  padding: 18px;
  overflow-y: auto;
  max-height: calc(85vh - 110px);
}
.step-edit-modal-footer {
  padding: 12px 18px;
  background: #f8fafc;
  border-top: 1px solid #e2e8f0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
